paperbot · PL 论文追踪

全部论文 待读 收藏

P2 Type-Outference with Label-Listeners: Foundations for Decidable Type-Consistency for Nominal Object-Oriented Generics

带标签监听器的类型外推:面向名义式面向对象泛型的可判定类型一致性的基础
OOPSLA 9(OOPSLA2)2025匹配度 2/10 · 该论文属于纯PL类型系统与可判定性形式化验证,核心是名义式OO泛型的类型外推,与用户关注的LLM/Agentic程序静态分析、LLM辅助静态分析、浮点或贝叶斯程序分析均无直接交叉;仅在“形式化验证/静态分析理论基础”大方向上略有背景关联。引用 0 inbox
Ross Tate
crossref: 2026-09-10

AI 速览

一句话:首个可靠完备判定过程:无表达式类型标注、含不规则递归泛型接口的名义式OO程序可验证;标签监听器和类型一致性实现类型外推。

本文研究名义式面向对象泛型语言中表达式缺少类型标注时的程序验证问题,尤其针对具有不规则递归签名泛型接口,这类语言难以沿用结构化类型的可判定性方案。作者将事件驱动的标签监听器引入约束系统,按需生成程序验证的复杂条件,同时保证终止;并提出类型一致性这一新的声明式程序有效性概念,可在无需类型推断所需复杂类型文法的情况下确保安全性。由于可推断性蕴含类型一致性而反之不成立,算法可不推断缺失类型而直接判定有效性,故称类型外推。作者在 Rocq 中机器化形式化并验证了类型一致性、类型外推与标签监听器,给出首个可靠且完备的判定过程,为超越结构化类型限制的可判定性奠定基础。

问题
如何在表达式无类型标注、泛型接口签名不规则递归的名义式面向对象程序中,实现可靠且完备的程序验证,并突破结构化类型对可判定性的限制。
方法
将事件驱动标签监听器融入约束系统以按需生成验证条件并保证终止,提出声明式类型一致性概念,并据此设计无需类型推断的类型外推算法;核心概念与算法在 Rocq 中机器化验证。
评估
通过 Rocq 机器化形式化与验证类型一致性、类型外推和标签监听器,论证判定过程的可靠性与完备性,并展示其面向现代大型带类型面向对象语言泛型特征的适用性。
原文摘要(Abstract)

We present the first sound and complete decision procedure capable of validating nominal object-oriented programs without type annotations in expressions even in the presence of generic interfaces with irregularlyrecursive signatures. Such interface signatures are exemplary of the challenges an algorithm must overcome in order to scale to the needs of modern major typed object-oriented languages. We do so by incorporating event-driven label-listeners into our constraint system, enabling more complex aspects of program validation to be generated on demand while still ensuring termination. Furthermore, we define type-consistency as a novel declarative notion of program validity that ensures safety without requiring a complex grammar of types to perform inference within. While type-inferability ensures type-consistency, the converse does not necessarily hold. Thus our algorithm decides program validity without inferring the types missing from the program, and so we instead call it a type-outference algorithm. By bypassing type-inference, the proofs involving type-consistency more directly connect the design of and reasoning about constraints to the operational semantics of the language, simplifying much of the design and verification process. We mechanically formalize and verify these concepts and techniques—type-consistency, type-outference, and label-listeners—in Rocq to provide a solid foundation for scaling decidability beyond the limitations of structural types.

链接与引用

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

BibTeX
@article{paperbot2927,
  title = {Type-Outference with Label-Listeners: Foundations for Decidable Type-Consistency for Nominal Object-Oriented Generics},
  author = {Ross Tate},
  journal = {Proceedings of the ACM on Programming Languages},
  volume = {9},
  number = {OOPSLA2},
  year = {2025},
  doi = {10.1145/3763797}
}