15 breaking releases
| new 0.16.0 | Dec 23, 2025 |
|---|---|
| 0.15.0 | Nov 27, 2025 |
| 0.14.0 | Oct 26, 2025 |
| 0.11.0 | Jul 25, 2025 |
#843 in Parser implementations
3,172 downloads per month
Used in 2 crates
12MB
370K
SLoC
This crate provides Rust language support for the tree-sitter parsing library.
Typically, you will use the LANGUAGE constant to add this language to a
tree-sitter Parser, and then use the parser to parse some code:
let code = r#"
fn double(x: i32) -> i32 {
x * 2
}
"#;
let mut parser = tree_sitter::Parser::new();
let language = tree_sitter_rust_orchard::LANGUAGE;
parser
.set_language(&language.into())
.expect("Error loading Rust parser");
let tree = parser.parse(code, None).unwrap();
assert!(!tree.root_node().has_error());
tree-sitter-rust-orchard
This is a fork of the tree-sitter-rust grammar. It focuses on:
- faithfulness of the produced trees with the semantics of Rust
- ability to parse Rust files with recent syntactic constructs
- proactive reviewing of contributions and onboarding of their authors into the project, via the governance model
Note that unlike upstream, generated files are not checked into git, so you need to run tree-sitter generate after cloning this repository.
Contributions are welcome, so are co-maintainers.