Files
lucisv/CHANGELOG.md
T
lucioandClaude Fable 5 26a59c1d6a Add release-prep: vfmt 0.2.0, LICENSE, CHANGELOG, release tooling
Version bumped to 0.2.0 (workspace-inherited, one line + lockfiles;
both binaries report it). Root MIT LICENSE plus the editors/vscode
copy that lets vsce package run without --skip-license, closing the
editor-packaging handshake. CHANGELOG.md is a user-facing first-
release document: six area paragraphs linking the feature READMEs,
stating the current corpus truth (476/820 formattable, zero
verification errors, zero crashes). tools/release.sh builds
checksummed host binaries + the sideloadable .vsix into gitignored
dist/ (aborts before deleting prior artifacts on failure -- proven
live); tools/RELEASING.md is the checklist, with marketplace/OpenVSX
commands demoted to an explicitly optional appendix per the owner:
publishing is fully deferred, sideloading via code
--install-extension is the supported path, publisher stays
REPLACE-ME.

Dev: Opus agent (mid-flight scope trim handled cleanly); QA: Sonnet
agent (artifacts, real sideload cycle, all 26 changelog links);
review in docs/features/release-prep/README.md.

Co-Authored-By: Claude Fable 5 <[email protected]>
2026-08-19 12:39:10 -07:00

7.3 KiB

Changelog

All notable changes to vfmt are recorded here. Versions follow semantic versioning; until 1.0 the CLI's exit codes (see README.md) are the only frozen contract.

0.2.0 — 2026-08-19

The first released version. 0.1.0 was the workspace's initial version number and was never tagged or published, so these notes describe vfmt as it stands rather than a delta against a shipped predecessor.

vfmt is a formatter, a linter and a language server for Verilog-2001 and the synthesizable SystemVerilog subset — one parser and one style engine behind a CLI (vfmt) and an LSP binary (vfmt-server).

Formatter and the safety net

Formatting is Wadler/prettier-style: every breakable construct is a group that stays on one line if it fits within the line limit and otherwise breaks one element per line, over the full statement, expression, declaration, instantiation, generate, function/task and typedef grammar. Defaults follow Verible — 2-space indent, 100-column lines. Comments are attached as leading and trailing trivia and are never dropped. Every format is verified at runtime: the output is re-lexed and its token stream (comments included) compared against the input, then formatted a second time and checked for a fixed point; if either check fails the output is discarded and the file is left byte-for-byte untouched. // verilog_format: off / // vfmt: off fences return the enclosed items as their exact source bytes, indentation included. Deep nesting is a normal parse error with a position rather than a stack overflow. Details: formatter, safety net, fences, comment attachment and round 2, case tables, spans, recursion limit.

Command line

vfmt <paths> formats files and directories in place. --check and --diff are the CI modes (exit 1 if anything would change, nothing written); - reads stdin, with --stdin-filename naming the buffer. Directory walks honor .gitignore (a documented subset) and repeatable --exclude patterns, and run on all cores — --threads N pins the worker count without changing a single output byte, since results are collected in input order. Settings live in a vfmt.toml / .vfmt.toml discovered upward from each input, ruff-style, with CLI flags taking precedence per setting; an unknown key or a bad value is a hard error naming the file and line. The exit-code contract (0 / 1 / 2) is frozen and documented. A panic on one file cannot take down the run. Details: CLI, config discovery, parallel walk.

Linter

vfmt check is a ruff-shaped linter over the same files, the same walk and the same config discovery as the formatter: a rule registry, --select / --ignore, --output-format json, and fixes classified safe or unsafe with --fix applying only the safe ones. Eight syntactic rules ship — no-tabs, no-trailing-whitespace, case-missing-default, always-ff-non-blocking, always-comb-blocking, explicit-parameter-storage-type, module-filename and unused-waiver. Inline waivers use Verible's spelling (// vfmt: waive <rule>, waive-start / waive-stop, with verilog_lint: accepted as an alias), so code already annotated for Verible lints unedited. check runs on the error-tolerant parser, so a file the formatter refuses is still linted for what can be read. Violations inside a format fence are reported but never auto-fixed, by the same shared computation the formatter uses. Details: linter, shared fence filter, error recovery.

Language server

vfmt-server speaks LSP over stdio from a single binary and serves every editor the same answers: textDocument/formatting (honoring the file's own vfmt.toml, which wins over the editor's tab size), parse errors and lint warnings in one diagnostic publish per change, codeAction quick fixes plus source.fixAll.vfmt for fix-on-save, semanticTokens/full, hover (declaration snippets and `define expansion, in-file and across the workspace), go-to-definition, in-file references, and document and workspace symbols. Underneath it are a single-file semantic model (scopes, symbols, references) and a workspace index that resolves names arriving through package imports and module instantiations across files. Not yet advertised, and said so out loud: range formatting, cross-file references, completion, rename and signature help. Details: server, lint wiring, semantic model, workspace index, define table, name spans, shared core.

Editors

A thin VS Code extension in editors/vscode/ registers the file types (.v/.vh → verilog, .sv/.svh → systemverilog) and starts the server; it has one setting, vfmt.serverPath, and no language logic of its own — everything a user sees comes from the server. Install it by building the .vsix and sideloading it (tools/release.sh, then code --install-extension); publishing to a marketplace is optional and deferred. editors/nvim/README.md documents the equivalent Neovim 0.11+, nvim-lspconfig, Vim 9 vim-lsp and coc.nvim configuration — no plugin needed. editors/vscode/smoke.js is a zero-dependency check that spawns the server exactly as the extension does and drives a full LSP session, so a failure can be pinned on the binary or on the editor config without guessing. Details: editor packaging.

Real-world corpus

vfmt is measured against an 820-file corpus of open-source RTL (picorv32, ibex, common_cells, OpenTitan) rather than against its own fixtures alone. At this release 476 of 820 files (58.0%) parse and format cleanly, with zero verification errors and zero crashes — every file vfmt cannot handle is a documented parse error, never a corrupted output. The remaining gap is unsupported syntax, ranked by measured impact in README.md's roadmap: classes/constraints (the largest block, and mostly DV rather than RTL), bind, dynamic arrays and queues, identifier-typed declarations, then concurrent assertions and DPI. Macro invocations at module-item and statement position and compiler directives inside port, parameter, enum, override and connection lists were the two blockers closed during this cycle; no corpus file is blocked on a compiler directive any more. Details: corpus check, corpus bugs, macro items, directives in lists and in instances.