A K Definition of Scheme

This paper presents an executable rewriting logic semantics of RRS Scheme using the K definitional technique [19]. We refer to this definition as K-Scheme. The presented semantics follows the K language definitional style but is almost entirely equational. It can also be regarded as a denotational specification with an initial model semantics of Scheme. Equational specifications can be executed on common rewrite engines, provided that equations are oriented into rewrite rules, typically from left-to-right. The rewriting logic semantics in this paper is the most complete formal definition of Scheme that we are aware of, in the sense that it provides definitions for more Scheme language features than any other similar attempts. The presented executable definition, K-Scheme, can serve as a platform for experimentation with variants and extensions of Scheme, for example concurrency. K-Scheme also serves to show the viability of K as a definitional framework for programming languages.

[1]  Marcelo d'Amorim,et al.  An Equational Specification for the Scheme Language , 2005, J. Univers. Comput. Sci..

[2]  José Meseguer,et al.  Rewriting logic: roadmap and bibliography , 2002, Theor. Comput. Sci..

[3]  Gordon D. Plotkin,et al.  A structural approach to operational semantics , 2004, J. Log. Algebraic Methods Program..

[4]  José Meseguer,et al.  Rewriting Logic Semantics: From Language Specifications to Formal Analysis Tools , 2004, IJCAR.

[5]  Gilles Kahn,et al.  Natural Semantics , 1987, STACS.

[6]  Narciso Martí-Oliet,et al.  Maude: specification and programming in rewriting logic , 2002, Theor. Comput. Sci..

[7]  Robert Bruce Findler,et al.  An operational semantics for R5RS Scheme , 2005 .

[8]  R. Kent Dybvig,et al.  The Scheme Programming Language , 1995 .

[9]  Peter D. Mosses,et al.  Modular structural operational semantics , 2004, J. Log. Algebraic Methods Program..

[10]  Grigore Rosu,et al.  KOOL: An Application of Rewriting Logic to Language Prototyping and Analysis , 2007, RTA.

[11]  José Meseguer,et al.  Conditioned Rewriting Logic as a United Model of Concurrency , 1992, Theor. Comput. Sci..

[12]  Grigore Rosu K: a Rewrite-based Framework for Modular Language Design, Semantics, Analysis and Implementation -Version 1- , 2005 .

[13]  Grigore Rosu,et al.  On Formal Analysis of OO Languages Using Rewriting Logic: Designing for Performance , 2007, FMOODS.

[14]  José Meseguer,et al.  The Rewriting Logic Semantics Project , 2006, SOS@ICALP.

[15]  José Meseguer,et al.  A Rewriting Logic Approach to Operational Semantics (Extended Abstract) , 2007, Electron. Notes Theor. Comput. Sci..

[16]  Robert Hieb,et al.  Revised 5 Report on the Algorithmic Language , 1999 .

[17]  José Meseguer,et al.  Formal Analysis of Java Programs in JavaFAN , 2004, CAV.

[18]  Matthias Felleisen,et al.  A Syntactic Approach to Type Soundness , 1994, Inf. Comput..

[19]  Gérard Berry,et al.  The chemical abstract machine , 1989, POPL '90.