Closed amaanq closed 2 months ago
This now uses
tree-sitter-language
to export the grammar, instead of relying on a cyclic dependency of itself, which caused a whole slew of issues.
Sorry for the naive question, but how would one adapt an expression like this?
Query::new(&tree_sitter_go::language(), source).unwrap()
Sorry, I think I figured it out. I need to call <Language as From<LanguageFn>>::from
: https://docs.rs/tree-sitter/0.23.0/tree_sitter/struct.Language.html#impl-From%3CLanguageFn%3E-for-Language
Yeah, something like Query::new(&tree_sitter_go::LANGUAGE.into(), source).unwrap()
should work.
This now uses
tree-sitter-language
to export the grammar, instead of relying on a cyclic dependency of itself, which caused a whole slew of issues.