Partial evaluation of general parsers

  • Authors:
  • Christian Mossin

  • Affiliations:
  • Univ. of Copenhagen, Copenhagen, Denmark

  • Venue:
  • PEPM '93 Proceedings of the 1993 ACM SIGPLAN symposium on Partial evaluation and semantics-based program manipulation
  • Year:
  • 1993

Quantified Score

Hi-index 0.00

Visualization

Abstract

Applications of partial evaluation have so far mainly focused on generation of compilers from interpreters for programming languages. We partially evaluate a simple general LR(k) parsing algorithm. To obtain good results, we rewrite the algorithm using a number of binding-time improvements. The final LR(1) parser has been specialized using Similix, a partial evaluator for a higher order subset of Scheme [3]. The obtained specialized parsers are efficient and compact.Partial evaluation is responsible for the (equivalent of) the sets-of-items construction, and the construction of parsing tables.This paper is an extended abstract of [14].