ABS的状态行为类型
Stateful Behavioral Types for ABS
摘要:
众所周知,要正确实现一个涉及异步/并发交互和多个参与者状态约束的多方协议是非常困难的。为了帮助开发人员实现这样的协议,我们提出了一种新的规约语言,以指定多个面向对象的演员和堆内存上的这些演员的副作用的相互作用,提出了一个基于行为类型的分析类型检查。我们的规约语言将协议形式化为一个全局类型,它用一阶逻辑描述了异步方法调用的过程、期货的使用以及堆的副作用。为了描述类型实例的运行,我们给出了类型的模型理论语义,并将其转换为对轨迹的逻辑约束。我们证明协议的遵守:如果一个程序是w.r.t.一个协议,那么程序的每一个踪迹都遵守该协议,即,每个迹线都是其类型的公式的模型。
英文摘要:
It is notoriously hard to correctly implement a multiparty protocol which involves asynchronous/concurrent interactions and the constraints on states of multiple participants. To assist developers in implementing such protocols, we propose a novel specification language to specify interactions within multiple object-oriented actors and the side-effects on heap memory of those actors; a behavioral-type-based analysis is presented for type checking. Our specification language formalizes a protocol as a global type, which describes the procedure of asynchronous method calls, the usage of futures, and the heap side-effects with a first-order logic. To characterize runs of instances of types, we give a model-theoretic semantics for types and translate them into logical constraints over traces. We prove protocol adherence: If a program is well-typed w.r.t. a protocol, then every trace of the program adheres to the protocol, i.e., every trace is a model for the formula of its type.
机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。