arXivDaily arXiv每日学术速递 周一至周五更新
北美退伍军人节(Veterans Day),12 日无更新
arXiv 1104.3116cs.PL
收藏

简单的、可判定的子类型类型推断

Simple, Decidable Type Inference with Subtyping

Eli Gottlieb

摘要:

我们展示了一种方法来推断多态的主要和子类型的ML类核心语言的最小类型分配范围内的类型变量。我们证明了该算法的终止性和完整性,并继续表明,它解决了一个广泛的特殊情况下,一般不可判定的半统一问题。我们的过程不需要类型注释,在推断的类型中不留下子类型约束,并且不产生证明义务。我们展示了我们的技术的实际效用,通过显示一个类型保持编码的Featherweight Java到表达式演算,我们推断类型。

英文摘要:

We demonstrate a method to infer polymorphically principal and subtyping-minimal types for an ML-like core language by assigning ranges within a lattice to type variables. We demonstrate the termination and completeness of this algorithm, and proceed to show that it solves a broad special-case of the generally-undecidable semi-unification problem. Our procedure requires no type annotations, leaves no subtyping constraints in the inferred types, and produces no proof obligations. We demonstrate the practical utility of our technique by showing a type-preserving encoding of Featherweight Java into the expression calculus over which we infer types.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑