UDC 004.4, DOI: 10.2298/CSIS1002291P

Annotation Based Parser Generator

Jaroslav Porubän1, Michal Forgáč1, Miroslav Sabo1 and Marek Běhálek2

  1. Department of Computers and Informatics, Technical University of Košice
    Letná 9, 042 00 Košice, Slovak Republic
    {Jaroslav.Poruban, Michal.Forgac, Miroslav.Sabo}@tuke.sk
  2. Department of Computer Science, FEI VŠB Technical University of Ostrava
    17. listopadu 15, 708 33 Ostrava-Poruba, Czech Republic
    marek.behalek@vsb.cz

Abstract

The paper presents innovative parser construction method and parser generator prototype which generates a computer language parser directly from a set of annotated classes in contrast to standard parser generators which specify concrete syntax of a computer language using BNF notation. A language with textual concrete syntax is defined upon the abstract syntax definition extended with annotations in the presented approach. Annotations define instances of concrete syntax patterns in a language. Abstract syntax of a language is inevitable input of the parser generator as well as language’s concrete syntax pattern definitions. The process of parser implementation is presented on the concrete computer language – the Simple Arithmetic Language. The paper summarizes results of the studies of implemented parser generator and describes its role in the university courses.

Key words

parser generator; annotated model; abstract syntax; model to grammar transformation

Digital Object Identifier (DOI)

https://doi.org/10.2298/CSIS1002291P

Publication information

Volume 7, Issue 2 (April 2010)
Advances in Languages, Related Technologies and Applications
Year of Publication: 2010
ISSN: 2406-1018 (Online)
Publisher: ComSIS Consortium

Full text

DownloadAvailable in PDF
Portable Document Format

How to cite

Porubän, J., Forgáč, M., Sabo, M., Běhálek, M.: Annotation Based Parser Generator. Computer Science and Information Systems, Vol. 7, No. 2, 291-307. (2010), https://doi.org/10.2298/CSIS1002291P