Clojure, without the JVM.

cljrs is a Clojure dialect implemented from scratch in Rust. The reader, evaluator, macros, and persistent collections run as a tree walker. Type-hinted functions compile to native code through MLIR and LLVM. GPU kernels compile to WGSL and run on Metal, Vulkan, DX12, or WebGPU.

One language, three compilers

;; Tree walker. Fully dynamic, lowest ceremony.
(defn avg [xs] (/ (reduce + xs) (count xs)))

;; Native. Same syntax, type-hinted, JIT-compiled to machine code.
(defn-native fib ^i64 [^i64 n]
  (if (< n 2) n (+ (fib (- n 1)) (fib (- n 2)))))

;; GPU. Same syntax, compiles to a compute shader.
(defn-gpu doubled ^f32 [^i32 i ^f32 v]
  (* v 2.0))

Run it

⌘↵ to run, tree walker compiled to WASM
click Run

Status