All Manuals > LispWorks® User Guide and Reference Manual > 21 The Parser Generator

21.1 Introduction

The parser generator generates an LALR parser from a specification of a grammar. The parser generator has a simple facility for the static resolution of ambiguity in the grammar and supports an automatic run time error correction mechanism as well as user-defined error correction. Semantic actions can be included in the rules for the grammar by specifying Lisp forms to be evaluated when reductions are performed. When using a generated parser, you need to specify a lexer that generates (grammar) tokens (see 21.5 Interface to the lexical analyzer).

For further details on LALR parsing, see Compilers, Principles Techniques and Tools, by Aho, Sethi and Ullman, publishers Addison Wesley, 1986.

Load the parser generator by (require "parsergen").


LispWorks® User Guide and Reference Manual - 01 Dec 2021 19:30:23