#luau #parser #incremental


luau grammar for the tree-sitter parsing library

2 stable releases

1.1.0 Jan 24, 2024
1.0.0 Jun 21, 2023

#12 in #luau

23 downloads per month

MIT license

25K SLoC

C 24K SLoC Scheme 328 SLoC // 0.1% comments JavaScript 279 SLoC // 0.1% comments Rust 34 SLoC // 0.1% comments


Build Status Discord

Luau grammar for tree-sitter.

Adapted from the syntax spec


This crate provides Luau 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 = "";
let mut parser = tree_sitter::Parser::new();
parser.set_language(tree_sitter_luau::language()).expect("Error loading Luau grammar");
let tree = parser.parse(code, None).unwrap();


~71K SLoC