1 unstable release

Uses new Rust 2024

0.1.0 Jul 7, 2025

#8 in #clojure

Download history 1615/week @ 2025-11-27 1979/week @ 2025-12-04 1321/week @ 2025-12-11 1172/week @ 2025-12-18 1380/week @ 2025-12-25 1676/week @ 2026-01-01 1789/week @ 2026-01-08 2569/week @ 2026-01-15 2690/week @ 2026-01-22 2406/week @ 2026-01-29 3041/week @ 2026-02-05 3182/week @ 2026-02-12 2846/week @ 2026-02-19 2724/week @ 2026-02-26 3351/week @ 2026-03-05 3878/week @ 2026-03-12

13,247 downloads per month
Used in 18 crates (6 directly)

MIT license

1MB
26K SLoC

C 25K SLoC JavaScript 368 SLoC // 0.2% comments Rust 29 SLoC // 0.1% comments Scheme 18 SLoC // 0.1% comments

This crate provides Clojure language support for the tree-sitter parsing library.

Typically, you will use the [LANGUAGE][] constant to add this language to a tree-sitter Parser, and then use the parser to parse some code:

use tree_sitter::Parser;

let code = r#"
(defn double [x] (* x 2))
"#;
let mut parser = Parser::new();
let language = tree_sitter_clojure::LANGUAGE;
parser
    .set_language(&language.into())
    .expect("Error loading Clojure parser");
let tree = parser.parse(code, None).unwrap();
assert!(!tree.root_node().has_error());

tree-sitter-clojure

This repository contains a grammar for the Clojure language for Tree-sitter. More specifically, it is the grammar from the tree-sitter-clojure repository. This repo exists to maintain Clojure support for Harper.

Feel free to use this package however you want.

Dependencies

~2.6–4MB
~77K SLoC