arXivDaily arXiv每日学术速递 周一至周五更新
感恩节,周五至周末无更新,大家顺遂。周一再来吧
arXiv 1307.8204cs.PL
收藏

用于交叉点类型检查的注释

Annotations for Intersection Typechecking

Jana Dunfield

摘要:

在函数式程序设计语言中,注释的经典形式是对术语的单一类型约束。交叉类型增加了复杂性:单个术语可能必须在不同的上下文中针对不同的类型进行多次检查,需要使用多种类型进行注释。此外,指出每种类型的使用环境是有用的(在某些系统中是必要的)。本文探讨了系统中的注释与交叉类型的技术设计空间。早期的工作(Dunfield and Pfenning 2004)引入了上下文类型注释,现在我们将其梳理成更基本的机制:“右手”注释(标准形式),“左手”注释(使用右手注释的上下文),允许多个注释的合并,以及索引变量的存在绑定器。最新颖的元素是左侧注释,它用必须从当前上下文得出的判断来保护术语(和右侧注释)。

英文摘要:

In functional programming languages, the classic form of annotation is a single type constraint on a term. Intersection types add complications: a single term may have to be checked several times against different types, in different contexts, requiring annotation with several types. Moreover, it is useful (in some systems, necessary) to indicate the context in which each such type is to be used. This paper explores the technical design space of annotations in systems with intersection types. Earlier work (Dunfield and Pfenning 2004) introduced contextual typing annotations, which we now tease apart into more elementary mechanisms: a "right hand" annotation (the standard form), a "left hand" annotation (the context in which a right-hand annotation is to be used), a merge that allows for multiple annotations, and an existential binder for index variables. The most novel element is the left-hand annotation, which guards terms (and right-hand annotations) with a judgment that must follow from the current context.

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

↑