2 releases
0.0.2 | Mar 21, 2024 |
---|---|
0.0.1 | Mar 21, 2024 |
#2775 in Parser implementations
92KB
3.5K
SLoC
tree-sitter-pest
The Pest grammar for the tree-sitter.
Usage
cargo add tree-sitter-pest
License
MIT
lib.rs
:
This crate provides pest language support for the tree-sitter parsing library.
Typically, you will use the language function to add this language to a tree-sitter Parser, and then use the parser to parse some code:
let code = "";
let mut parser = tree_sitter::Parser::new();
parser.set_language(tree_sitter_pest::language()).expect("Error loading pest grammar");
let tree = parser.parse(code, None).unwrap();
Dependencies
~2.8–4MB
~77K SLoC