Dependent types allow us to express precisely what a function is intended to do. Recent work on Quantitative Type Theory (QTT) extends dependent type systems with linearity, also allowing precision in expressing when a function can run. This is promising, because it suggests the ability to design and reason about resource usage protocols, such as we might find in distributed and concurrent programming, where the state of a communication channel changes throughout program execution. As yet, however, there has not been a full-scale programming language with which to experiment with these ideas. Idris 2 is a new version of the dependently typed language Idris, with a new core language based on QTT, supporting linear and dependent types. In this paper, we introduce Idris 2, and describe how QTT has influenced its design. We give examples of the benefits of QTT in practice including: expressing which data is erased at run time, at the type level; and, resource tracking in the type system leading to type-safe concurrent programming with session types.


翻译:依附类型类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型 类型

0
下载
关闭预览

相关内容

专知会员服务
78+阅读 · 2021年3月16日
强化学习最新教程,17页pdf
专知会员服务
182+阅读 · 2019年10月11日
【新书】Python编程基础,669页pdf
专知会员服务
197+阅读 · 2019年10月10日
机器学习入门的经验与建议
专知会员服务
94+阅读 · 2019年10月10日
Call for Participation: Shared Tasks in NLPCC 2019
中国计算机学会
5+阅读 · 2019年3月22日
逆强化学习-学习人先验的动机
CreateAMind
16+阅读 · 2019年1月18日
强化学习的Unsupervised Meta-Learning
CreateAMind
18+阅读 · 2019年1月7日
A Technical Overview of AI & ML in 2018 & Trends for 2019
待字闺中
18+阅读 · 2018年12月24日
分布式TensorFlow入门指南
机器学习研究会
4+阅读 · 2017年11月28日
VIP会员
相关VIP内容
专知会员服务
78+阅读 · 2021年3月16日
强化学习最新教程,17页pdf
专知会员服务
182+阅读 · 2019年10月11日
【新书】Python编程基础,669页pdf
专知会员服务
197+阅读 · 2019年10月10日
机器学习入门的经验与建议
专知会员服务
94+阅读 · 2019年10月10日
相关资讯
Call for Participation: Shared Tasks in NLPCC 2019
中国计算机学会
5+阅读 · 2019年3月22日
逆强化学习-学习人先验的动机
CreateAMind
16+阅读 · 2019年1月18日
强化学习的Unsupervised Meta-Learning
CreateAMind
18+阅读 · 2019年1月7日
A Technical Overview of AI & ML in 2018 & Trends for 2019
待字闺中
18+阅读 · 2018年12月24日
分布式TensorFlow入门指南
机器学习研究会
4+阅读 · 2017年11月28日
Top
微信扫码咨询专知VIP会员