|
ABSTRACTS OF ARTICLES OF THE JOURNAL "INFORMATION TECHNOLOGIES".
No. 10. Vol. 24. 2018
DOI: 10.17587/it.24.648-656
L. N. Lyadova, Associate Professor, e-mail: LLyadova@hse.ru, A. O. Sukhov, Associate Professor, e-mail: ASuhov@hse.ru, E. Yu. Medvedeva, Master Student, e-mail: medvedevaeyu@mail.ru, National Research University Higher School of Economics, Perm, 614070, Russian Federation
Syntactic Parsing Algorithms for Textual Domain-Specific Languages
Over time an increasing number of software packages have provided users with domain-specific languages designed to customize the system in accordance with changing operating conditions and user needs. However, it is necessary to create language workbenches for such languages. The authors suggested an approach to developing toolkits for creating textual dynamically customizable domain-specific languages that allow eliminating the limitations of most existing language workbenches. The purpose of the study is to develop algorithms for parsing language grammar and checking syntactic correctness of the programs. These algorithms are necessary for implementing a language workbench.
As a means of representing the transitional results of the domain-specific language grammar analysis a parsing pseudo tree is used, which makes it possible to improve the efficiency of language constructions searching at the stage of checking the program's syntactic correctness.
The parsing algorithm is based on the left-recursive descent method with backtracking. Despite the exponential complexity, the algorithm makes it possible to provide the possibility of dynamically changing the language description.
Functions of language syntax highlighting and code completing also use the parsing pseudo tree in their work. These functions simplify the process of model building and reading and reduce the number of errors in it.
Keywords: grammar analysis, syntax checking, domain-specific languages, textual languages, language workbench, left-recursive descent parser, formal grammars, parse tree, metalanguage, model-oriented approach
P. 648–656
To the contents |
|