?
Алгоритмы синтаксического разбора для текстовых динамически настраиваемых предметно-ориентированных языков
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.