Term Evaluation Systems with Refinements: First-Order, Second-Order, and Contextual Improvement

被引:0
|
作者
Muroya, Koko [1 ]
Hamana, Makoto [2 ]
机构
[1] Kyoto Univ, RIMS, Kyoto, Japan
[2] Kyushu Inst Technol, Kitakyushu, Fukuoka, Japan
关键词
term rewriting; evaluation contexts; critical pair analysis;
D O I
10.1007/978-981-97-2300-3_3
中图分类号
TP31 [计算机软件];
学科分类号
081202 ; 0835 ;
摘要
For a programming language, there are two kinds of term rewriting: run-time rewriting ("evaluation") and compile-time rewriting ("refinement"). Whereas refinement resembles general term rewriting, evaluation is commonly constrained by Felleisen's evaluation contexts. While evaluation specifies a programming language, refinement models optimisation and should be validated with respect to evaluation. Such validation can be given by Sands' notion of contextual improvement. We formulate evaluation in a term-rewriting-theoretic manner for the first time, and introduce Term Evaluation and Refinement Systems (TERS). We then identify sufficient conditions for contextual improvement, and provide critical pair analysis for local coherence that is the key sufficient condition. As case studies, we prove contextual improvement for a computational lambda-calculus and its extension with effect handlers.
引用
收藏
页码:31 / 61
页数:31
相关论文
共 50 条