instaparse

If you're not trampolining your parser, why bother getting up in the morning?
Empperi 2017-11-01T13:27:01.000384Z

does someone happen to know if there is a ready tool to convert W3C EBNF declarations to format which instaparse understands?

Empperi 2017-11-01T13:27:21.000008Z

specifically I’m looking for SPARQL ebnf declarations which I could feed into instaparse

Empperi 2017-11-01T13:32:33.000404Z

I would also accept an ANTLR -> instaparse converter

2017-11-01T16:07:09.000222Z

instaparse understands the SPARQL grammar from w3c. you just have to adapt the production rules for the terminals so that instaparse will detect them as regexes. See for instance https://github.com/mladvladimir/sparqlom/blob/master/resources/sparql.ebnf