Skip to content

Commit

Permalink
latest grammar does not have issue
Browse files Browse the repository at this point in the history
  • Loading branch information
ilevyor committed Mar 19, 2024
1 parent e52a29d commit 395398c
Show file tree
Hide file tree
Showing 30 changed files with 893,539 additions and 535,233 deletions.
12 changes: 12 additions & 0 deletions crates/language/src/tsx.rs
Original file line number Diff line number Diff line change
Expand Up @@ -512,4 +512,16 @@ mod tests {
println!("{:#?}", nodes);
assert!(!nodes.is_empty());
}

#[test]
fn parse_file() {
let mut parser = Parser::new().unwrap();
let ts = tree_sitter_typescript::language_tsx().into();
parser.set_language(&ts).unwrap();
let text = include_str!("../test.ts");
let tree = parser.parse(text, None).unwrap().unwrap();
let root = tree.root_node();
let sexp = root.to_sexp();
println!("{sexp}");
}
}
Binary file modified crates/wasm-bindings/wasm_parsers/tree-sitter-javascript.wasm
Binary file not shown.
Binary file modified crates/wasm-bindings/wasm_parsers/tree-sitter-tsx.wasm
Binary file not shown.
Binary file modified crates/wasm-bindings/wasm_parsers/tree-sitter-typescript.wasm
Binary file not shown.
Loading

0 comments on commit 395398c

Please sign in to comment.