Skip to content

Application of the generated parser as a compiler's parser #831

Discussion options

You must be logged in to vote

I think the biggest downside to using a Tree-sitter parser in a compiler front-end is that, while we've done a lot of work on Tree-sitter's error recovery, we haven't yet built out functionality for error messages. So it isn't trivial to find out the exact token/position where the error initiated, and get a list of expected tokens, and things like that.

Also, the error recovery currently isn't customizable in domain-specific ways (e.g. as soon as the word "function" appears, assume that the user meant to write an entire function definition).

Down the road, I would love to invest in both of these things, but because there's so much other stuff we're working on, it may be a while before thi…

Replies: 5 comments 10 replies

Comment options

You must be logged in to vote
1 reply
@resolritter
Comment options

Comment options

You must be logged in to vote
1 reply
@resolritter
Comment options

Answer selected by resolritter
Comment options

You must be logged in to vote
1 reply
@maxbrunsfeld
Comment options

Comment options

You must be logged in to vote
2 replies
@resolritter
Comment options

@marcel0ll
Comment options

Comment options

You must be logged in to vote
5 replies
@ljleb
Comment options

@Jachdich
Comment options

@NicholasLYang
Comment options

@sgraf812
Comment options

@VonTum
Comment options

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
10 participants
Converted from issue

This discussion was converted from issue #831 on December 04, 2020 17:25.