LSP & Editor Setup
visuall-lsp is a Language Server Protocol server that brings Visuall language support to any LSP-compatible editor.
Capabilities
| Feature | Description |
|---|---|
| Diagnostics | Real-time error and warning underlines with range highlighting |
| Completion | Scope-aware autocomplete (trigger: ., (, ", ') |
| Hover | Type information and documentation on hover |
| Go to Definition | Jump to symbol definitions (cross-file via workspace index) |
| Find References | List all usages of a symbol across the workspace |
| Document Symbols | Breadcrumb outline of functions, classes, and scopes |
| Workspace Symbols | Fuzzy search for symbols across all project files |
| Formatting | Full-document formatting |
| Inlay Hints | Inline type annotations and parameter names |
| Semantic Tokens | Syntax highlighting (keywords, functions, classes, etc.) |
| Signature Help | Function parameter hints on ( and , trigger |
| Code Actions | Quick fixes (missing return, typo suggestions) |
| Rename | Cross-file symbol renaming |
| Incremental Sync | Efficient range-based document sync for large files |
Building
The LSP builds alongside the compiler when BUILD_LSP=ON (default):
cd build
cmake .. -DBUILD_LSP=ON
cmake --build . --target visuall-lsp
The binary visuall-lsp will be in build/tools/visuall-lsp/.
Editor Setup
VS Code
Add to settings.json:
"visuall.lsp.path": "/path/to/build/tools/visuall-lsp/visuall-lsp" Neovim
Using nvim-lspconfig:
local lspconfig = require('lspconfig')
lspconfig.visuall_lsp = {
cmd = { '/path/to/visuall-lsp' },
filetypes = { 'visuall' },
root_dir = lspconfig.util.root_pattern('vsl.toml', '.git'),
} Other Editors
visuall-lsp implements standard LSP over stdio. Configure any LSP-compatible editor
(Helix, Emacs, Zed, etc.) to launch visuall-lsp for .vsl files.
The server discovers project structure by looking for a vsl.toml or
.git directory at the workspace root, and indexes all .vsl
files under it.