paperbot · PL 论文追踪

全部论文 待读 收藏

P2 An extended account of contract monitoring strategies as patterns of communication

将契约监控策略视为通信模式的扩展论述
JFP vol.282018匹配度 2/10 · 论文属于形式语义与契约监控,虽涉及形式化验证,但未涉及用户核心关注的 LLM/Agent 与静态分析/形式化验证交叉、浮点程序分析或贝叶斯程序分析,与研究方向匹配度低。引用 4 inbox
CAMERON SWORDS, AMR SABRY, SAM TOBIN-HOCHSTADT
crossref: 2026-09-10

AI 速览

一句话:将契约检查统一重构为并发进程间通信,并在核心演算中嵌入多种监控策略及证明其正确性。

软件工程中契约系统有多种执行策略,如 Eiffel 的前后条件检查、惰性、可选和并行执行等,但每种策略通常都要从零构建监控系统。论文观察到契约本质上是程序与监控器之间的通信,因此把契约检查重构为并发进程之间的通信。该视角揭示了严格、惰性及并发等执行策略之间的内在联系,并将它们嵌入一个核心演算中;作者还通过模拟给出了一种编码的正确性证明。最后,该框架能够启发此前无法表达的新监控方法和契约。

问题
契约系统执行策略多样且各自独立实现,缺乏统一理解与比较框架,也难以发现新策略。
方法
将契约检查视为程序与监控器之间的并发通信,把严格、惰性及并发等监控策略嵌入核心演算,并用模拟证明一种编码的正确性。
评估
通过核心演算中的形式化编码与一种编码的模拟正确性证明来评估统一框架,并展示其能提出新的监控方法与契约。
原文摘要(Abstract)

Abstract Contract systems have come to play a vital role in many aspects of software engineering. This has resulted in a wide variety of approaches to enforcing contracts—ranging from the straightforward pre-condition and post-condition checking of Eiffel to lazy, optional, and parallel enforcement strategies. Each of these approaches has its merits, but each has required ground-up development of an entire contract monitoring system. We present a unified approach to understanding this variety, while also opening the door to as-yet-undiscovered strategies. By observing that contracts are fundamentally about communication between a program and a monitor, we reframe contract checking as communication between concurrent processes. This brings out the underlying relations between widely studied enforcement strategies, including strict and lazy enforcement as well as concurrent approaches, including new contracts and strategies. We show how each of these can be embedded into a core calculus, and demonstrate a proof (via simulation) of correctness for one such encoding. Finally, we show that our approach suggests new monitoring approaches and contracts not previously expressible.

链接与引用

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

BibTeX
@article{paperbot332,
  title = {An extended account of contract monitoring strategies as patterns of communication},
  author = {CAMERON SWORDS and AMR SABRY and SAM TOBIN-HOCHSTADT},
  journal = {Journal of Functional Programming},
  volume = {28},
  year = {2018},
  doi = {10.1017/s0956796818000047}
}