Projects per year
Abstract
We establish a semantics for building grammars from a modularised speci-
cation in which modules are able to delete productions from imported nonterminals.
Our goal is to allow a precise answer to the question: `what character
level language does this grammar generate' in the face of dicult issues such
as the mutual embedding of languages that have dierent whitespace and
commenting conventions. Our technique is to automatically generate a character
level grammar from grammars written at token level in the conventional
way; the grammar is constructed from modules each of which may have its
own whitespace convention. Modules have import lists of nonterminals; some
or all of an imported nonterminal's productions may be suppressed at import
time. There are two basic import mechanisms which (a) reference or
(b) clone an imported nonterminal's productions. We conclude with a set
of examples using the concrete syntax from our ART GLL parser generator
tool.
cation in which modules are able to delete productions from imported nonterminals.
Our goal is to allow a precise answer to the question: `what character
level language does this grammar generate' in the face of dicult issues such
as the mutual embedding of languages that have dierent whitespace and
commenting conventions. Our technique is to automatically generate a character
level grammar from grammars written at token level in the conventional
way; the grammar is constructed from modules each of which may have its
own whitespace convention. Modules have import lists of nonterminals; some
or all of an imported nonterminal's productions may be suppressed at import
time. There are two basic import mechanisms which (a) reference or
(b) clone an imported nonterminal's productions. We conclude with a set
of examples using the concrete syntax from our ART GLL parser generator
tool.
Original language | English |
---|---|
Pages (from-to) | 23-43 |
Number of pages | 21 |
Journal | Science of Computer Programming |
Volume | 87 |
Early online date | 1 Oct 2013 |
DOIs | |
Publication status | Published - 1 Jul 2014 |
Keywords
- Context Free Grammar, Modularity, Whitespace processing
Projects
- 1 Finished
-
PLanCompS: PLanCompS: Programming Language Components and Specifications
Johnstone, A. (PI), Scott, E. (CoI), Reddington, J. (CoI) & Walsh, R. (CoI)
Eng & Phys Sci Res Council EPSRC
1/06/11 → 31/05/15
Project: Research