Executable Relational Specifications of Polymorphic Type Systems Using Prolog.

FLOPS(2016)

引用 24|浏览13
暂无评分
摘要
A concise, declarative, and machine executable specification of the Hindley–Milner type system (HM) can be formulated using logic programming languages such as Prolog. Modern functional language implementations such as the Glasgow Haskell Compiler support more extensive flavors of polymorphism beyond Milner’s theory of type polymorphism in the late 70’s. We progressively extend the HM specification to include more advanced type system features. An interesting development is that extending dimensions of polymorphism beyond HM resulted in a multi-staged solution: resolve the typing relations first, while delaying to resolve kinding relations, and then resolve the delayed kinding relations. Our work demonstrates that logic programing is effective for prototyping polymorphic type systems with rich features of polymorphism, and that logic programming could have been even more effective for specifying type inference if it were equipped with better theories and tools for staged resolution of different relations at different levels.
更多
查看译文
关键词
Hindley–Milner, Functional language, Type system, Type inference, Unification, Parametric polymorphism, Higher-kinded polymorphism, Type constructor polymorphism, Kind polymorphism, Algebraic datatype, Nested datatype, Logic programming, Prolog, Delayed goals
AI 理解论文
溯源树
样例
生成溯源树,研究论文发展脉络
Chat Paper
正在生成论文摘要