A modal type system for multi-level generating extensions with persistent code

  • Authors:
  • Yosihiro Yuse;Atsushi Igarashi

  • Affiliations:
  • Kyoto University;Kyoto University

  • Venue:
  • Proceedings of the 8th ACM SIGPLAN international conference on Principles and practice of declarative programming
  • Year:
  • 2006

Quantified Score

Hi-index 0.00

Visualization

Abstract

Multi-level generating extensions, studied by Glück and Jørgensen, are generalization of (two-level) program generators, such as parser generators, to arbitrary many levels. By this generalization, the notion of persistent code---a quoted code fragment that can be used for different stages---naturally arises.In this paper we propose a typed λ calculus λ circle square, based on linear-time temporal logic, as a basis of programming languages for multi-level generating extensions with persistent code. The key idea of the type system is correspondence of (1) linearly ordered times in the logic to computation stages; (2) a formula circle A (next A) to a type of code that runs at the next stage; and (3) a formula circle A (always A) to a type of persistent code executable at and after the current stage. After formalizing (λ circle square), we prove its key property of time-ordered normalization that a well-typed program can never go back to a previous stage in a "time-ordered" execution, as well as basic properties such as subject reduction, confluence and strong normalization. Commuting conversion plays an important role for time-ordered normalization to hold