Anyway, still watching videos about parsers and I'm starting to think all parsing should happen in language servers. Implementing syntax highlighting is a lot of work. Every editor needs to implement it for each language. And two parsers have to be run on each keystroke.
[1]: it's possible to build on the work of parsers such as tree sitter for this, so it's not quite as bad. But it'd still be nicer to only have to implement a single point integration.
-
-
I've been having a look at the jetbrains MPS project lately (trying to get an idea of its edges)... it feels much closer to that single-point deliberation than I had expected
-
"that single-point deliberation" — what do you mean by that?
- 1 more reply
New conversation -
-
-
@maxbrunsfeld recently added support to tree-sitter for defining the syntax highlighting rules for a language using nice pattern-matching rules. http://tree-sitter.github.io/tree-sitter/using-parsers#pattern-matching-with-queries … We’re starting to shift highlighting on http://github.com to use that for some languages -
So for a new editor you’d have to wrap the TSQuery bits of the C API but shouldn’t have to reimplement any of the actual highlighting logic.
- 1 more reply
New conversation -
Loading seems to be taking a while.
Twitter may be over capacity or experiencing a momentary hiccup. Try again or visit Twitter Status for more information.