plum

#treesitter#compiler#wasm

git clone https://git.pyrossh.dev/plum

A statically typed, imperative programming language inspired by rust, python


fcd5c0aPeter John 2026-07-19T17:29:43+05:30
fix: use body-anchored indent annotations instead of per-construct = tokens
tooling/tree-sitter-plum/queries/plum/format.scm CHANGED
@@ -82,14 +82,5 @@
82
82
  ; Indentation — body blocks
83
83
  ; ============================================================
84
84
 
85
- ; Start indent after the = that opens a body in fn/class/trait/enum
85
+ ; Start indent before body content, end indent after the body node
86
- (fn "=" @append_hardline @append_indent_start)
87
- (class "=" @append_hardline @append_indent_start)
88
- (trait "=" @append_hardline @append_indent_start)
89
- (if "=" @append_hardline @append_indent_start)
90
- (for "=" @append_hardline @append_indent_start)
91
- (while "=" @append_hardline @append_indent_start)
92
- (match "=" @append_hardline @append_indent_start)
93
-
94
- ; End indent after each body node
95
- (body) @append_indent_end
86
+ (body) @prepend_indent_start @append_indent_end