Skip to content

koto-lang/tree-sitter-koto

Folders and files

NameName
Last commit message
Last commit date

Latest commit

f4e6423 · Apr 9, 2025
Apr 23, 2024
Apr 8, 2025
Apr 9, 2025
Apr 9, 2025
Dec 7, 2023
Apr 23, 2024
Apr 17, 2024
Oct 22, 2024
Dec 7, 2023
Jan 4, 2024
Dec 4, 2023
Apr 23, 2024
Apr 23, 2024
Apr 17, 2024
Apr 23, 2024
Apr 9, 2025
Dec 7, 2023
Apr 8, 2025
Oct 23, 2024
Oct 23, 2024
Apr 23, 2024
Apr 23, 2024
Oct 23, 2024

Repository files navigation

tree-sitter-koto

Tree-sitter parser for Koto.

Current State

The parser is mostly usable, but there are some bugs that result in valid Koto expressions not being correctly processed.

Contributions would be very welcome! See the failing tests for a couple of examples of expressions that could be worked on.

Development

The justfile contains some commands that are useful during development, in particular just test which will generate the tree-sitter parser from grammar.js and then run the tests contained in test/corpus.

just watch test will re-run just test when files are updated.

Arguments can be passed to just watch test, e.g. just watch test --debug -f identifiers will generate the parser with debug logging enabled, and then run only the identifiers test.

src/scanner.c contains the external scanner used by the grammar, handling some of the more complex aspects of parsing Koto code. Debug logging for the scanner can be enabled via a preprocesser definition at the top of the file.