Back to Search Start Over

Parser combinators for context-free path querying

Authors :
Semyon V. Grigorev
Ilya Kirillov
Ilya Nozkin
Ekaterina Verbitskaia
Source :
SCALA@ICFP
Publication Year :
2018
Publisher :
ACM, 2018.

Abstract

Transparent integration of a domain-specific language for specification of context-free path queries (CFPQs) into a general-purpose programming language as well as static checking of errors in queries may greatly simplify the development of applications using CFPQs. LINQ and ORM can be used for the integration, but they have issues with flexibility: query decomposition and reusing of subqueries are a challenge. Adaptation of parser combinators technique for paths querying may solve these problems. Conventional parser combinators process linear input, and only the Trails library is known to apply this technique for path querying. Trails suffers the common parser combinators issue: it does not support left-recursive grammars and also experiences problems in cycles handling. We demonstrate that it is possible to create general parser combinators for CFPQ which support arbitrary context-free grammars and arbitrary input graphs. We implement a library of such parser combinators and show that it is applicable for realistic tasks.

Details

Database :
OpenAIRE
Journal :
Proceedings of the 9th ACM SIGPLAN International Symposium on Scala
Accession number :
edsair.doi...........197ec413a92a93022db85d06ce6d0b1b
Full Text :
https://doi.org/10.1145/3241653.3241655