计算机科学 > 程序设计语言
[提交于 2023年11月17日]
标题:Polymorphic Type Inference for Dynamic Languages
查看原文 PDF 中文 PDF (下批处理) EasyResearch 阅读摘要:We present a type system that combines, in a controlled way, first-order polymorphism with intersectiontypes, union types, and subtyping, and prove its safety. We then define a type reconstruction algorithm that issound and terminating. This yields a system in which unannotated functions are given polymorphic types(thanks to Hindley-Milner) that can express the overloaded behavior of the functions they type (thanks tothe intersection introduction rule) and that are deduced by applying advanced techniques of type narrowing(thanks to the union elimination rule). This makes the system a prime candidate to type dynamic languages.
提交历史
来自:Kim Nguyen[v1] 2023年11月17日 星期五 10:00:47 UTC