paperbot · PL 论文追踪

全部论文 待读 收藏

P2 Exceptional asynchronous session types: session types without tiers

异常异步会话类型:无需层级(tiers)的会话类型
POPL 3(POPL)2019匹配度 3/10 · 该论文研究异步会话类型与异常处理的集成,属于类型系统/并发领域,与用户关注的ML/Agentic程序静态分析、浮点程序分析、贝叶斯程序分析等核心方向无直接关联。虽兼具形式化与工程实现,但主题不匹配。引用 52 inbox
Simon Fowler, Sam Lindley, J. Garrett Morris, Sára Decova
crossref: 2026-09-10

AI 速览

一句话:首次将异步会话类型与异常处理集成到函数式语言,给出核心演算与 Links 实现。

会话类型可静态保证通信遵循协议,但多数会话类型系统不处理失败,因此在故障常见的真实应用尤其是分布式应用中用途有限。本文首次在函数式编程语言中形式化集成异步会话类型与异常处理。作者定义一个核心演算,证明其满足保持性与进展性,且无死锁、合流并终止。作者还通过扩展 Links Web 编程语言,给出首个面向成熟函数式语言的带异常处理会话类型实现,实现借鉴 effect handlers。评估包括双因素认证示例,以及一个更大的基于会话的聊天应用,其中通信通过会话类型化通道进行并能优雅处理断连。

问题
会话类型能静态保证通信协议,但多数工作未处理失败,难以用于故障普遍的分布式应用。
方法
在函数式语言中形式化集成异步会话类型与异常处理,定义满足保持性、进展性、无死锁、合流且终止的核心演算,并基于 effect handlers 在 Links 中实现。
评估
通过双因素认证的示例和更大的基于会话的聊天应用(含断连处理)展示方法。
原文摘要(Abstract)

Session types statically guarantee that communication complies with a protocol. However, most accounts of session typing do not account for failure, which means they are of limited use in real applications---especially distributed applications---where failure is pervasive. We present the first formal integration of asynchronous session types with exception handling in a functional programming language. We define a core calculus which satisfies preservation and progress properties, is deadlock free, confluent, and terminating. We provide the first implementation of session types with exception handling for a fully-fledged functional programming language, by extending the Links web programming language; our implementation draws on existing work on effect handlers. We illustrate our approach through a running example of two-factor authentication, and a larger example of a session-based chat application where communication occurs over session-typed channels and disconnections are handled gracefully.

链接与引用

DOI 原文 · PDF(开放获取) ·

BibTeX
@article{paperbot676,
  title = {Exceptional asynchronous session types: session types without tiers},
  author = {Simon Fowler and Sam Lindley and J. Garrett Morris and Sára Decova},
  journal = {Proceedings of the ACM on Programming Languages},
  volume = {3},
  number = {POPL},
  year = {2019},
  doi = {10.1145/3290341}
}