ANN: antlr4ng 3.0 - The best TypeScript runtime for ANTLR4

38 views
Skip to first unread message

Mike Lischke

unread,
Mar 2, 2024, 3:56:59 PMMar 2
to 'ANTLR announcements
Hi,

I'm happy to announce the next major release of the antlr4ng TypeScript runtime, which has been greatly improved.

This release completes the conversion of the Java (and JavaScript) ANTRL4 runtime to TypeScript. It's a significant improvement over the existing TS (and JS) runtimes, as it includes now all relevant parts from the Java runtime and has been optimised for performance. It's now twice as fast for cold runs and 20% faster with a warm parser/lexer. Except for small tests where the JS runtime still shines by a very small margin, this one is faster than any other tested TypeScript and JavaScript runtime (antlr4, antlr4ts and antlr4wasm). See the original times taken before the optimisation and the comparison with the other runtimes (https://github.com/mike-lischke/antlr4wasm/tree/master/benchmarks/mysql) and compare that to the latest numbers in the antlr4ng repo (https://github.com/mike-lischke/antlr4ng/).

Beside the speed improvements there are a number of API changes (hence the new major version), which require some adjustments in your code when you upgrade to this release. If you see problems with it don't hesitate to open an issue in the repo (https://github.com/mike-lischke/antlr4ng/issues). The new release is available as NPM package too (https://www.npmjs.com/package/antlr4ng).

Regards,


Reply all
Reply to author
Forward
0 new messages