On Monday, December 7, 2020 at 11:58:21 AM UTC-6, Jeffrey H. Coffield wrote:
Not sure what you are trying to accomplish here, but some work was done parsing PostScript using Antlr which has some interesting error
handling. I have just started using Antlr4 myself and at some point will probably look at using it to parse PostScript forms.
Jeff Coffield
I want to write parser *in* PostScript, not just *for* PostScript. And I think the parser combinators make for a nice way do it, despite the difficulty in translating it to a non-lazy language. But I did a whole bunch of work
before realizing that the lack of error messages made the whole thing
rather unusable. But it's quite possible I'm overlooking a simpler way to
go about it. It's possible possible that postscript isn't the right tool for the job.
But in the interim, I've had some success with implementing lazy evaluation
and translating the result to working (complicated) C. So if I can get a prototype that produces nice error messages easily from some kind of
annotated grammar, I can translate that to C and have a nice interface
for writing parsers in C.
--- SoupGate-Win32 v1.05
* Origin: fsxNet Usenet Gateway (21:1/5)