News for hackers. Stuff that matters.
Re:Why not to use (f)lex, yacc or bison by rajnathani on Thursday March 05, 2020 @03:46AM (#22491974)
This is actually pretty true based upon what I've personally observed too. While Apache Spark [0] and Presto [1] use ANTLR to implement their parsers, when I searched about TypeScript's parser and noticed that they implement their own parser [2] (in TypeScript itself), the reason I was able to find was that the nuanced error messages which a language like TypeScript has to provide is only feasible by hand-writing the parser.

[0] https://github.com/apache/spark/blob/master/sql/catalyst/src...

[1] https://github.com/prestodb/presto/blob/master/presto-parser...

[2] https://github.com/microsoft/TypeScript/blob/master/src/comp...

Re:Why not to use (f)lex, yacc or bison by lloydatkinson on Thursday March 05, 2020 @04:05AM (#22492063)
> the nuanced error messages which a language like TypeScript has to provide is only feasible by hand-writing the parser.

I wonder if this is relevant to how bad the error messages generally are in Typescript.