But for example how do you parse the difference between `x = 14; x` and `y = 14; x`? In the latter case `x` is a method call, and in the former it's a local variable read. I can't see where the parser maintains a set of local variables and where it queries this set. Is it somehow done declaratively? If so that's a huge achievement I don't think that's really been done before in a parser generator.
I really want to try tree-sitter for using in an actual Ruby implementation because it's so beautiful!
I really want to try tree-sitter for using in an actual Ruby implementation because it's so beautiful!