当前位置: X-MOL 学术Sci. Comput. Program. › 论文详情
Our official English website, www.x-mol.net, welcomes your feedback! (Note: you will need to create a separate account there.)
Mechanical incrementalization of typing algorithms
Science of Computer Programming ( IF 1.3 ) Pub Date : 2021-04-16 , DOI: 10.1016/j.scico.2021.102657
Matteo Busi , Pierpaolo Degano , Letterio Galletta

The ever-growing size of programs and their continuous evolution require building fast and efficient analyzers. Here we focus on the static ones, in particular on type systems, for both checking and inference. Just as programs change by incrementally changing or inserting pieces of code, called diffs, also type systems should be incremental and re-type the diffs, only.

An algorithmic schema is proposed that mechanically derives an incremental version of existing, standard typing algorithms. Ours is a grey-box approach: just the shape of the typing rules, that of the types and some domain-specific knowledge are needed to instantiate our schema. Here, we present the foundations of our approach and the conditions for its correctness. Our schema is applied to derive four incremental typing and inference algorithms for languages in different programming paradigms. We implemented an OCaml module that inputs a type system and outputs its incrementalized version. Experimental results show that our approach is effective, and prove its usage beneficial.



中文翻译:

输入算法的机械增量

程序规模的不断扩大及其不断发展,需要构建快速,高效的分析仪。在这里,我们将重点放在静态检查上,尤其是类型系统上,以进行检查和推断。正如程序通过递增地更改或插入称为diffs的代码来进行更改一样,键入系统也应该是递增的,并且仅重新键入diffs

提出了一种算法方案,该方案以机械方式派生现有标准键入算法的增量版本。我们的方法是灰盒子的方法:实例化我们的模式只需要键入规则的形状,类型的形状和特定于领域的知识。在这里,我们介绍了我们的方法的基础以及正确性的条件。我们的模式适用于针对不同编程范例中的语言推导四种增量类型和推理算法。我们实现了OCaml模块,该模块输入类型系统并输出其增量版本。实验结果表明,该方法是有效的,并证明了其用法的有效性。

更新日期:2021-04-16
down
wechat
bug