aboutsummaryrefslogtreecommitdiff
path: root/bindings/rust/lib.rs
diff options
context:
space:
mode:
Diffstat (limited to 'bindings/rust/lib.rs')
-rw-r--r--bindings/rust/lib.rs10
1 files changed, 5 insertions, 5 deletions
diff --git a/bindings/rust/lib.rs b/bindings/rust/lib.rs
index ee3d344..7bc923a 100644
--- a/bindings/rust/lib.rs
+++ b/bindings/rust/lib.rs
@@ -1,4 +1,4 @@
-//! This crate provides apinotation language support for the [tree-sitter][] parsing library.
+//! This crate provides api-notation language support for the [tree-sitter][] parsing library.
//!
//! Typically, you will use the [language][language func] function to add this language to a
//! tree-sitter [Parser][], and then use the parser to parse some code:
@@ -6,7 +6,7 @@
//! ```
//! let code = "";
//! let mut parser = tree_sitter::Parser::new();
-//! parser.set_language(tree_sitter_apinotation::language()).expect("Error loading apinotation grammar");
+//! parser.set_language(tree_sitter_api_notation::language()).expect("Error loading api-notation grammar");
//! let tree = parser.parse(code, None).unwrap();
//! ```
//!
@@ -18,14 +18,14 @@
use tree_sitter::Language;
extern "C" {
- fn tree_sitter_apinotation() -> Language;
+ fn tree_sitter_api_notation() -> Language;
}
/// Get the tree-sitter [Language][] for this grammar.
///
/// [Language]: https://docs.rs/tree-sitter/*/tree_sitter/struct.Language.html
pub fn language() -> Language {
- unsafe { tree_sitter_apinotation() }
+ unsafe { tree_sitter_api_notation() }
}
/// The content of the [`node-types.json`][] file for this grammar.
@@ -47,6 +47,6 @@ mod tests {
let mut parser = tree_sitter::Parser::new();
parser
.set_language(super::language())
- .expect("Error loading apinotation language");
+ .expect("Error loading api-notation language");
}
}