arXivDaily arXiv每日学术速递 周一至周五更新
arXiv周末暂无论文更新,休息一下吧,周末愉快~~
arXiv 1806.03476cs.PL
收藏

模式中的类型变量

Type variables in patterns

Richard A. Eisenberg, Joachim Breitner, Simon Peyton Jones

摘要:

多年来,GHC实现了对Haskell的扩展,允许类型变量绑定在类型签名和模式中,并在术语上起作用。从未正确指定此扩展名。我们在这里纠正这个疏忽。有了正式的规范,在模式中绑定类型变量的设计之路就变得非常清晰了。因此,我们扩展了ScopedTypeVariables来显式地绑定类型变量,避免了将Proxy解决方案放入历史的垃圾箱。

英文摘要:

For many years, GHC has implemented an extension to Haskell that allows type variables to be bound in type signatures and patterns, and to scope over terms. This extension was never properly specified. We rectify that oversight here. With the formal specification in hand, the otherwise-labyrinthine path toward a design for binding type variables in patterns becomes blindingly clear. We thus extend ScopedTypeVariables to bind type variables explicitly, obviating the Proxy workaround to the dustbin of history.

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

↑