`ludic syntax [--json] [-o FILE]` prints what `ludicc --emit-syntax` does (a line per entry, or the JSON). `ludic-dev syntax` writes, between "ludic-dev syntax: begin" / "end" lines, the keyword, type, phase and attribute tables of ludic_syntax.h, LudicVocabulary's sets (JetBrains), ludic-mode.el's lists and the language server's word tests (is_keyword_word and the rest; is_contextual_word is every word the parser does not reserve, and every declaring or modifying one), and every TextMate pattern marked "comment": "ludic-dev syntax: <group>" (shared and the VS Code copy). The grammars gain module uses port bind action reducer dispatch registry def open component prop view alias friend unsafe numbers of as from mut system; import and extern colour as declarations; the phase clause knows Overlay; the bitwise pattern matches | and ^ on their own again. `ludic-dev syntax --check` - and check-vocabulary, whose old parser comparison it replaces, and the regression suite (syntax_cases, one line per file) - fails when a written list is behind, when a grammar lacks a keyword, type or phase, when docs/language has no page for a keyword, type, phase or attribute, or when the parser (a scan of selfhost/frontend: is_id / text == words, a == / ann == attributes) tests a word or reads an attribute vocab.ludic lacks, or the reverse. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> |
||
|---|---|---|
| .. | ||
| icons | ||
| snippets | ||
| src | ||
| syntaxes | ||
| .vscodeignore | ||
| language-configuration.json | ||
| package-lock.json | ||
| package.json | ||
| README.md | ||
Ludic for VS Code
Syntax highlighting, formatting, and full language-server support for Ludic,
the AI-first, ECS-native game language. See LANGUAGE.md in the Ludic repository
for the language reference.
What you get
| Source | |
|---|---|
| Syntax highlighting | TextMate grammar, works with no build |
| Semantic highlighting | ludic-lsp — real name resolution, so a component reads differently from a local |
| Diagnostics | structural errors as you type; ludicc's own errors on save |
| Completion | context-aware: fields after ., components inside query [...], phases after phase, widgets inside ui |
| Hover | signatures and docs for builtins, intrinsics, and everything you declared |
| Go to definition / references / rename | across every file in the compilation unit, following import |
| Formatting | format-on-save, comment-preserving |
| Outline, folding, inlay hints, signature help | |
```ludic fences in Markdown |
highlighted, checked, and formatted |
Setup
Build the toolchain once, from the repository root:
bin/ludic-dev tools
That produces bin/ludic-lsp and bin/ludic-fmt, which the extension finds
on its own. If you keep them elsewhere, set ludic.server.path.
Format on save:
"[ludic]": { "editor.formatOnSave": true }
Settings
ludic.server.path— whereludic-lsplives (~and${workspaceFolder}expand). Empty = searchbin/, thenPATH.ludic.server.enabled— turn the server off and keep only static highlighting.ludic.compilerPath— whereludicclives, for on-save diagnostics (~and${workspaceFolder}expand).ludic.compilerDiagnostics— whether to run the compiler at all.ludic.indentSize— spaces per level for the formatter.ludic.trace.server— log LSP traffic (Ludic: Show Language Server Log).
Installing without publishing
cd tools/editors/vscode
npm install
npx @vscode/vsce package
code --install-extension ludic-1.0.0.vsix