73 karma · joined February 27, 2022
Working on improving diff tools for developers!
We're looking for feedback from developers. If you share our frustrations with reviewing code changes, we'd love to talk to you. Most developers already have a favourite diff tool installed locally but there exists very little for reviewing code changes online, so we worked on DiffLens slowly over a number of years. We use it to review our own code changes, and we love it. We'd really appreciate thoughts and insights about the idea and its execution from developers and will answer any questions that come up. Thanks for reading!
Many of them are incomplete, but it gives a good idea of how the grammar looks for ANTLR.
I used the ANTLR grammar for parsing CSS in DiffLens (https://github.com/marketplace/difflens). DiffLens uses the typescript compiler itself to parse TS and JS.
I've also used Roslyn to parse C# (and F#). I wonder if the ruby compiler itself exposes a parser.
Separately, I'm curious about how a parser generated out of ANTLR/yacc etc compares to this hand written one? If you've done some benchmarking, it'd be great to see numbers!
If you work primarily with frontend technologies and want a syntax aware diff on GitHub PRs, difflens might be right up your alley! Standalone Mac and Windows apps are coming out soon.