Initial commit: Tree-sitter grammar for Hack Binary language

This commit is contained in:
2025-09-10 23:50:42 -04:00
commit d408c50827
9 changed files with 1153 additions and 0 deletions

37
tree-sitter.json Normal file
View File

@@ -0,0 +1,37 @@
{
"$schema": "https://tree-sitter.github.io/tree-sitter/assets/schemas/config.schema.json",
"grammars": [
{
"name": "hack_binary",
"camelcase": "HackBinary",
"title": "Hack Binary",
"scope": "source.hack_binary",
"file-types": ["hack"],
"injection-regex": "^hack[-_]?binary$",
"class-name": "TreeSitterHackBinary"
}
],
"metadata": {
"version": "1.0.0",
"license": "MIT",
"description": "A Tree-sitter grammar for parsing Hack Binary machine code (nand2tetris)",
"authors": [
{
"name": "Sean O'Connor",
"email": "sean@soconnor.dev"
}
],
"links": {
"repository": "https://github.com/soconnor0919/nand2tetris-zed"
}
},
"bindings": {
"c": true,
"go": false,
"node": true,
"python": false,
"rust": true,
"swift": false,
"zig": false
}
}