Skip Navigation

The Computer Journal 1989 32(1):36-44; doi:10.1093/comjnl/32.1.36
© 1989 by British Computer Society
This Article
Right arrow Full Text (PDF)
Right arrow Alert me when this article is cited
Right arrow Alert me if a correction is posted
Services
Right arrow Email this article to a friend
Right arrow Similar articles in this journal
Right arrow Similar articles in ISI Web of Science
Right arrow Alert me to new issues of the journal
Right arrow Add to My Personal Archive
Right arrow Download to citation manager
Right arrow Search for citing articles in:
ISI Web of Science (4)
Right arrowRequest Permissions
Google Scholar
Right arrow Articles by Edupuganty, B.
Right arrow Articles by Bryant, B. R.
Right arrow Search for Related Content
Social Bookmarking
 Add to CiteULike   Add to Connotea   Add to Del.icio.us  
What's this?

Two-level Grammar as a Functional Programming Language

B. Edupuganty1 * and B. R. Bryant2

1 Software Leverage, Inc., 485 Massachusetts Avenue, Arlington, Massachusetts, U.S.A. 02174., 2 Department of Computer and Information Sciences, The University of Alabama at Birmingham, Birmingham, Alabama, USA 35294

A two-level grammar consists of two context-free grammars interacting in a manner such that their combined computing power is equivalent to that of a Turing Machine. We show that two-level grammar can be used as a functional programming where the two-level grammar notation is the syntax of the language. Two-level grammar programs as represented are actually high-level descriptions of recursive functions, with one level of the grammar specifying the function domains and the second level defining the function evaluation rules. A general algorithm to interpret two-level grammars is given to make two-level grammar programs executable. The primary advantages of two-level grammar over other functional programming languages are (1) the capability for data and procedural abstraction provided by the different levels of the grammar and (2) the structured form of natural language which is used as the two-level grammar syntax, making two-level grammar programs very readable.


Received July 1986. revised September 1987.

* Present address: Software Leverage, Inc., 485 Massachusetts Avenue, Arlington, Massachusetts, U.S.A. 02174.

§ Department of Computer and Information Sciences, The University of Alabama at Birmingham, Birmingham, Alabama, U.S.A. 35294


Add to CiteULike CiteULike   Add to Connotea Connotea   Add to Del.icio.us Del.icio.us    What's this?




Disclaimer:
Please note that abstracts for content published before 1996 were created through digital scanning and may therefore not exactly replicate the text of the original print issues. All efforts have been made to ensure accuracy, but the Publisher will not be held responsible for any remaining inaccuracies. If you require any further clarification, please contact our Customer Services Department.