TOOLS & PROJECT

VS Code

Set up diagnostics, navigation, checked rename and formatting.

Ryft 0.3 additions and current limitations: see the 0.3 reference. Older baseline details below apply except where that reference supersedes them.

VS Code and language server

Install on Windows

Use Extensions → … → Install from VSIX and select build/ryft-language-0.3.0.vsix. The Windows package includes ryft.exe, so analysis/formatting need no compiler installation on PATH. Build commands need Cargo and the C++ toolchain. No Marketplace publication has occurred.

To override the bundled compiler, set ryft.compilerPath to an absolute executable path in VS Code settings. Empty selects the bundled Windows binary, then ryft on PATH. A trusted workspace is required for compiler execution.

Available features

Feature Behavior
Highlighting/snippets .rz association, keywords/types/comments/strings, app/function/route templates
Diagnostics Parser, type, route and capability errors on unsaved buffers; UTF-16 positions
Imports Imported source validation; imported errors identify the file and mark the importing declaration
Completion Keywords, standard library and declarations in the current file
Hover Builtin descriptions and declaration information
Definition/references Checked semantic targets across files and unsaved imports; lexical fallback for invalid buffers
Rename/signature help Scoped, rechecked workspace edits and checked function parameter information
Outline Function/app/struct/local/storage declarations
Formatting Four-space lexical formatter; preserves comments and literal spellings
Commands Check/build the manifest entry when available, otherwise the current file; restart the language server

Checked projects use a semantic index for cross-file definitions, references, scoped rename, hover and signature help, including unsaved imported buffers. Rename validates the edited project. Completion remains lexical; type annotation navigation, incomplete-call recovery, semantic tokens, code fixes and a source-level debugger remain incomplete.

CLI formatter

ryft fmt FILE.rz rewrites the file. --check returns failure if formatting is needed; --stdout prints without changing the file. The formatter preserves token order, comments and original string spellings. It accepts lexically valid text even if type checking fails. Object braces use multiline layout. The formatter is idempotent; comment placement may change to its own line.

LSP transport

ryft lsp speaks JSON-RPC with Content-Length framing over stdin/stdout. All protocol data uses stdout; compiler/process errors use stderr. It supports initialize/initialized/shutdown/exit, full-text open/change/close/save, publishDiagnostics, completion, hover, definition, references, prepareRename, rename, signatureHelp, documentSymbol and formatting. Sync is full-text, positions are UTF-16, messages are limited to 8 MiB and headers to 8 KiB. Cancellation notifications are accepted; analysis is serial. The LSP follows Microsoft’s protocol specification.

Set ryft.trace.server to messages/verbose for troubleshooting. If the server does not start, confirm the compiler path and run ryft --version. Use Restart Language Server after replacing a compiler. Custom LSP editors can invoke the same stdio command; only VS Code is packaged here.

Ryft 0.3.0Source: docs/editor.md

Search installation, types, routes, storage and more.