论文标题
全局类型的推理featherweight通用爪哇
Global Type Inference for Featherweight Generic Java
论文作者
论文摘要
Java的类型系统主要依赖于使用本地类型推断的类型检查来提高程序员的便利性。我们研究了功能性Java核心语言FeatherWeaight Generic Java(FGJ)的全球类型推断。给定通用类标题和现场规格,如果类不使用多态性递归,则我们的推论算法会渗透所有方法类型。该算法是基于约束的,并且在几个方面都改善了先前的工作。尽管设置有限,但FGJ的全局类型推断是NP库的。
Java's type system mostly relies on type checking augmented with local type inference to improve programmer convenience. We study global type inference for Featherweight Generic Java (FGJ), a functional Java core language. Given generic class headers and field specifications, our inference algorithm infers all method types if classes do not make use of polymorphic recursion. The algorithm is constraint-based and improves on prior work in several respects. Despite the restricted setting, global type inference for FGJ is NP-complete.