use tree_sitter::Language;
extern "C" {
fn tree_sitter_php() -> Language;
}
pub fn language() -> Language {
unsafe { tree_sitter_php() }
}
pub const NODE_TYPES: &'static str = include_str!("../languages/tree-sitter-php/src/node-types.json");
pub const HIGHLIGHTS_QUERY: &'static str =
include_str!("../languages/tree-sitter-php/queries/highlights.scm");
pub const INJECTIONS_QUERY: &'static str =
include_str!("../languages/tree-sitter-php/queries/injections.scm");
pub const TAGS_QUERY: &'static str = include_str!("../languages/tree-sitter-php/queries/tags.scm");
#[cfg(test)]
mod tests {
#[test]
fn test_can_load_grammar() {
let mut parser = tree_sitter::Parser::new();
parser
.set_language(super::language())
.expect("Error loading php language");
}
}