4 releases
0.1.6 | Oct 13, 2021 |
---|---|
0.1.5 | Sep 21, 2021 |
0.1.4 | Aug 30, 2021 |
0.1.3 |
|
#374 in Text editors
155KB
5K
SLoC
tree-sitter-dot
DOT grammar for tree-sitter.
lib.rs
:
This crate provides dot 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 = r#"
graph {
a -- b
}
"#;
let mut parser = tree_sitter::Parser::new();
parser.set_language(tree_sitter_dot::language()).expect("Error loading dot grammar");
let tree = parser.parse(code, None).unwrap();
Dependencies
~2.7–4MB
~72K SLoC