update rust bindings to include scanner and queries (#30)
Co-authored-by: Jonatan Kłosko <jonatanklosko@gmail.com>
This commit is contained in:
parent
b4027d7cfc
commit
c8d69759a7
|
@ -8,3 +8,7 @@
|
||||||
/build/
|
/build/
|
||||||
log.html
|
log.html
|
||||||
tree-sitter-elixir.wasm
|
tree-sitter-elixir.wasm
|
||||||
|
|
||||||
|
# Files generated by Cargo
|
||||||
|
/target/
|
||||||
|
Cargo.lock
|
||||||
|
|
|
@ -22,10 +22,6 @@ fn main() {
|
||||||
c_config.compile("parser");
|
c_config.compile("parser");
|
||||||
println!("cargo:rerun-if-changed={}", parser_path.to_str().unwrap());
|
println!("cargo:rerun-if-changed={}", parser_path.to_str().unwrap());
|
||||||
|
|
||||||
// If your language uses an external scanner written in C++,
|
|
||||||
// then include this block of code:
|
|
||||||
|
|
||||||
/*
|
|
||||||
let mut cpp_config = cc::Build::new();
|
let mut cpp_config = cc::Build::new();
|
||||||
cpp_config.cpp(true);
|
cpp_config.cpp(true);
|
||||||
cpp_config.include(&src_dir);
|
cpp_config.include(&src_dir);
|
||||||
|
@ -36,5 +32,4 @@ fn main() {
|
||||||
cpp_config.file(&scanner_path);
|
cpp_config.file(&scanner_path);
|
||||||
cpp_config.compile("scanner");
|
cpp_config.compile("scanner");
|
||||||
println!("cargo:rerun-if-changed={}", scanner_path.to_str().unwrap());
|
println!("cargo:rerun-if-changed={}", scanner_path.to_str().unwrap());
|
||||||
*/
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -35,10 +35,10 @@ pub const NODE_TYPES: &'static str = include_str!("../../src/node-types.json");
|
||||||
|
|
||||||
// Uncomment these to include any queries that this grammar contains
|
// Uncomment these to include any queries that this grammar contains
|
||||||
|
|
||||||
// pub const HIGHLIGHTS_QUERY: &'static str = include_str!("../../queries/highlights.scm");
|
pub const HIGHLIGHTS_QUERY: &'static str = include_str!("../../queries/highlights.scm");
|
||||||
// pub const INJECTIONS_QUERY: &'static str = include_str!("../../queries/injections.scm");
|
// pub const INJECTIONS_QUERY: &'static str = include_str!("../../queries/injections.scm");
|
||||||
// pub const LOCALS_QUERY: &'static str = include_str!("../../queries/locals.scm");
|
// pub const LOCALS_QUERY: &'static str = include_str!("../../queries/locals.scm");
|
||||||
// pub const TAGS_QUERY: &'static str = include_str!("../../queries/tags.scm");
|
pub const TAGS_QUERY: &'static str = include_str!("../../queries/tags.scm");
|
||||||
|
|
||||||
#[cfg(test)]
|
#[cfg(test)]
|
||||||
mod tests {
|
mod tests {
|
||||||
|
|
Loading…
Reference in New Issue