首页 | 本学科首页   官方微博 | 高级检索  
     


Modular grammar specification
Affiliation:1. Department of Computer Science, Royal Holloway, University of London, Egham, Surrey, United Kingdom;2. Eindhoven University of Technology, Mathematics and Computer Science, Den Dolech 2, NL-5612 AZ Eindhoven, The Netherlands
Abstract:We establish a semantics for building grammars from a modularised specification in which modules are able to delete productions from imported nonterminals. 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. One of our goals is to allow a precise answer to the question: ‘what character level language does this grammar generate’ in the face of difficult issues such as the mutual embedding of languages that have different 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.
Keywords:Context free grammar  Modularity  Whitespace processing
本文献已被 ScienceDirect 等数据库收录!
设为首页 | 免责声明 | 关于勤云 | 加入收藏

Copyright©北京勤云科技发展有限公司  京ICP备09084417号