@bherrmann: in comparison, instaparse is slow and memory-inefficient, but far easier to use and accepts more types of grammars
I've never actually used ANTLR so I'm just guessing on both points
Ha!
We have a large oracle grammar… in ANTLR and I’m curious about using instaparse instead
So it's already working in ANTLR?
Why would you want to switch?
(genuinely curious)
well. This might be the wrong reason
by when we make changes to the ANTLR grammar, it generates a java file which is too big to be compiled
so at the moment, we have to giggle the rules to keep the output small enough to be compiled.
It is ANTLR V3
That sounds... clumsy.
well, it that old song of someone understanding how ANTLR v3 works and them leaving the company....
I’m working with a modified version of this http://www.antlr3.org/grammar/1209225566284/PLSQL3.g
I should really read this https://tomassetti.me/antlr-mega-tutorial/
although that page is ANTLR V4
I’m curious if the PLSQL3.g could easily be consumed by Instaparse
The is_sql
thing actually looks like something unique to ANTLR (not standard BNF)
i.e. setting local variables
yea, that is weird
we dont use the is_sql in our copy.
so the grammar has about 1600 lines (ours has around 2k)… They appear otherwise very similar