Files
carbon-lang/utils/tree_sitter
Jon Ross-PerkinsandRichard Smith 38d25cf622 Share ReadFile in tests (#4967)
Small cleanup for code sharing. Note, `*ReadFile` will trigger a
CHECK-failure on error; the relevant implementations would previously
have failed silently (empty string).

---------

Co-authored-by: Richard Smith <richard@metafoo.co.uk>
2025-02-15 00:17:01 +00:00
..
2025-02-15 00:17:01 +00:00

Tree-sitter grammar for Carbon

Tree-sitter is currently used for syntax highlighting in supported editors.

Development

We use a non-hermetic tree-sitter invocation, so it must be installed locally. To install tree-sitter, run:

npm install -g tree-sitter-cli

Editor Installation

Helix

  1. Install tree-sitter and Nodejs.
  2. Install Helix.
  3. Run ./helix.sh

Emacs

TODO