TODO §71.5. One setting picks a house layout — [format] style in
lucisv.toml, --style, the lucisv.format.style drop-down, the server and MCP:
lucisv (default), google, lowrisc, ansi, microsoft, nxp, and auto. Seven
layout rules (indent, width, begin placement, else placement, else after a
labelled end, one-per-line lists, list indent, alignment), one row per style
in one table in crates/vlog_formatter/src/style.rs. google and lowrisc follow
those published guides; ansi, microsoft and nxp are lucisv's guesses and say
so. auto formats with each preset and keeps the result that changes the
fewest lines (crates/vlog_formatter/src/auto.rs); the language server
remembers each document's preset (lucisv_server/src/auto_style.rs) so
selection and on-type formatting do not repeat the search. The style is part
of the format cache key.
Proof: default output byte-identical to 0.65.4 on 4 921 files (corpus +
OpenTitan hw) against an independently rebuilt 0.65.4; every style formatted
three times over the same files with no verification error, crash, token or
comment difference (independent lexer) or second-run change. verify.rs is
untouched.
Dev (three rounds), QA (two rounds, pass with findings) and lead review are
in docs/features/format-styles/README.md. Three one-line calls were added to
lucisv_server/src/server/notification.rs for the memory's invalidation.
TODO.md files the pre-existing bugs QA met on the way.
Version bump (Cargo.toml, Cargo.lock, editors/vscode/package.json and both
package-lock.json spots); notes in CHANGELOG.md (## 0.65.5) and
editors/vscode/CHANGELOG.md.
Gates: tools/gates.sh PASS on this tree; vlog_formatter 376/0,
lucisv_server 1996/0, corpus 814/6.
Co-Authored-By: Claude Mythos 5.2 <[email protected]>
guard.sh fixes (both ours): the memory sum never saw a process three or
more levels down the tree (a doubled space became an empty entry in the
`ps -p` list, which macOS rejects whole), so cargo -> rustc -> linker and
test-spawned servers were never memory-limited — QA re-proved 1.5 GB at
depth 3/4 missed by master, killed in 2-4 s now; a closed stdin skipped
the command silently, now /dev/null. The stall itself is the host's
(syspolicyd on fresh unsigned binaries).
tools/gates.sh runs fmt, clippy, the test build, one suite per workspace
crate, the doc-tests, the corpus gate and the node tests as separate
guarded steps with kept logs and per-step limits; a guard-killed step is
retried once and shown as KILLED -> retried; usage errors exit 2 (lead
fixes after QA: comments/one-line/glob members, an empty crate list, a
missing option value, an empty selection). RELEASING.md step 3, CLAUDE.md
and the README's Building section point at it.
Ten consecutive green runs recorded (healthy host); full gate on master:
PASS, 15 steps, 5 127 tests, corpus 814/820. QA (Sonnet): PASS.
docs/features/release-gates.
Co-Authored-By: Claude Opus 5.5 <[email protected]>
crates/lucisv_mcp/src/cache.rs: at startup `--index-cache DIR/index-cache` (the language server's store) is read READ-ONLY — header CACHE_FORMAT/FACTS_FORMAT/version must match this build or the store is ignored with one stderr line; each record line's checksum verified, decoded, keyed by (record path, content hash) and used only for a discovered file whose bytes hash to it, through IndexBuilder::add_facts instead of a parse; the server never writes that file. Its own `index-cache-mcp` is written once at exit, atomically, in the same codec (a test pins the restated framing against index_cache.rs's source). opentitan: cold 1.9 s → warm 0.8 s (walk 210 ms + merge 204 ms are the floor). delete_item with force may remove an item holding `define/`undef, warning which macros went (M4's ruling); INSTRUCTIONS names the read tools, the edit tools, dry_run and diagnostics. Closing docs: docs/topo.md gains the lucisv_mcp node and its six edges, the mcp-packaging spawn/packaging rows, the read-only cache row and §2.9 rows 35–42 (MCP-5/6/7/8/10/11/12/13 and the parser leniency the M3.5 verifier exposed); repository-analysis map row and nine-crate count; README architecture row; CLAUDE.md measurement for the new crate.
QA (Opus; interrupted by the owner moving the machine, verdict pass so far): swapped/stale/foreign/deleted/off-by-one-header/CRLF stores skipped, the editor's store byte-identical through a session, SIGKILL mid-write harmless, a 231 MB store linear, fingerprint parity over the whole checkout; two low items open — the README threat model reworded, and an orphaned `.tmp` after a kill between write and rename to be swept in the census round. Gates: fmt, clippy clean; lucisv_mcp 318 passed; the dev's workspace run 4 858 passed on the same code.
Co-Authored-By: Claude Fable 5.1 <[email protected]>
tools/release.sh builds -p lucisv_mcp for the host and every cross triple, stages lucisv-mcp[.exe] beside the two binaries (three per platform package, fifteen in the all-platforms one; the universal package still carries none), smoke-tests it (editors/vscode/mcp_smoke.js: initialize, tools/list ≥ 26, project_overview) loose and unzipped from the host and all-platforms packages; tools/audit_artifacts.sh audits the third name and rejects any other; prune_release_assets.sh unchanged (seven vsix names). editors/vscode/mcp.js: the three-rung binary ladder (lucisv.mcp.path → bundled → PATH), one McpStdioServerDefinition per workspace folder — the constructor is POSITIONAL (label, command, args, env, version) with cwd set afterwards; the plan's object form was wrong and is corrected — with `--root <folder> --index-cache <storage>`, refreshed on folder and setting changes, guarded so VS Code < 1.101 registers nothing but the command; a missing binary refused at resolve time with one output-channel line; the `lucisv.mcp.copyConfig` command puts the Claude Code / Cursor / VS Code snippet on the clipboard. package.json: contributes.mcpServerDefinitionProviders, lucisv.mcp.enabled/path, the command; engine stays ^1.82.0 (vsce 4 accepts). ci.yml runs node --test over the extension's unit tests. Docs: docs/site guides/agents.md with the tool table generated from the binary (site rebuilt), README paragraph, RELEASING.md, extension README/CHANGELOG (Unreleased), manual-acceptance rows 18–25 for the live-VS Code checks.
QA (Opus): API signature confirmed against VS Code 1.138's vscode.d.ts; 8 mutation checks caught by mcp_test.js; release.sh run end to end, vsix contents listed (three binaries, mcp.js, no test files), SHA256SUMS verified, the embedded binary smoke-tested, the vsix installed into an isolated profile. Gates: node --test 6/6, fmt clean.
Co-Authored-By: Claude Fable 5.1 <[email protected]>
TODO §54 (docs/features/coverage-gaps-l); closes docs/coverage_gaps.md
L3, L6 and L10. The first dev stalled under machine load; a second
finished from the tree.
54.1 `->>` with optional delay or event control (`StmtKind::EventTrigger`),
stream `with [range]` (`ExprKind::StreamWith`), the LRM's other
`casting_type`s, drive strength on a net declaration (`DataDecl::strength`,
whose comment slots also fix a pre-existing refusal on an `assign` with
a comment before its strength), `let` at statement position
(`StmtKind::Let`), and `#(min:typ:max)` clocking skews — `ClockingSkew`
as the LRM's two alternatives, `edge [delay]` | `delay` (review rework of
QA's HIGH). Comment slots added to `let`, stream concatenations and the
clocking grammar; the RTL gap fuzzer at 505 gaps, zero failing.
54.2 `randsequence` (it was a parse error; the keyword is new):
`RandSequence` → `Production` → `Alternative` → `ProdItem` (ref, block,
if, repeat, case, rand join), code blocks by the statement grammar; one
production per line, alternatives aligned; the LRM's examples as cases.
54.3 `[format] uvm-utils-indent` / `lucisv.format.uvmUtilsIndent`, default
off, tracking nested `_begin`/`_end` pairs; 21 corpus files change with
it on, all idempotent. A short comment-free enum body already one-lines,
so no key was built — the behaviour is pinned. `[format]` table tests
added (review rework). `->>`'s event control is bound through the shared
`bind_timing` (review rework of QA's second HIGH).
0 of 820 corpus files differ from 0.48.x with the key off; the opentitan
sweep is identical; no corpus or opentitan file writes any of the new
shapes.
Co-Authored-By: Claude Fable 5.1 <[email protected]>
TODO §52 (docs/features/organize-imports), the third §8 refactoring.
The judgement lives in `vlog_semantic::imports` (one implementation for
the refactoring and the rule): an import is used when a reference in its
scope, or one nested in it, resolves to a member of the package through
it — `resolve::lexical`'s walk stopped at the scope, every import whose
path admits the name and whose package exports it (binder tables
same-file, `members_of_chain` with re-exports otherwise) marked used, a
deliberate superset; a qualified `p::y` and an import's own package name
never count; an `export p::x` / `export p::*` / `export *::*` in the
scope marks the import it re-exports through as used (IEEE 1800 §26.6 —
the review rework of QA's HIGH, pinned four ways). Refuse to judge: an
unknown or twice-declared package, a macro call or conditional directive
anywhere in the scope, a class with an out-of-file base, a parse
diagnostic, two imports on one line. `vlog_refactor::organize_imports`
deletes the unused lines, merges exact duplicates, sorts the run at the
scope's top (package, item, `*` first), keeps every comment; the
verifier's resolution check refuses a removal a reference needs (attack
pair). `unused-import` (Style, off; safe fix) through
`MentionOracle::package_exports`, silent without a project. Server:
`lucisv: organize imports (removes N, sorts M)` under
`source.organizeImports`, `lucisv.organizeImports`.
Corpus: 40 scopes with ≥ 2 imports, 1 organized, 32 refused for macros;
the rule finds 2, both substantiated. opentitan: 33 of 33 UVM env
packages refused (`` `include "uvm_macros.svh" ``). 0 of 860 corpus
files differ from 0.46.0.
Co-Authored-By: Claude Fable 5.1 <[email protected]>
TODO §49 (docs/features/hierarchical-tail). Closes topo §2.9-23 and
comment-slots finding 2. The first dev was cut off by an outage with the
library half complete; a second finished the tests, README and gates.
`Surface { Connection, Hierarchical }` on `Resolution::ExternalCandidate`
and `MemberSite::Unit`, set by `resolve.rs::head_surface` for an instance
head. `workspace/hierarchy.rs`: `surface_of` (the export rule, re-ruled)
and the two surface-taking reads; the index keeps two disjoint tables —
`members` (connection: ports, parameters; byte-identical to before for
every existing reader) and `hier_members` (nets, variables, instances) —
and a hierarchical read consults the connection table first, so a port
has one record. `FACTS_FORMAT` 18 → 19. `assign w = u_x.sig;` in another
file now resolves to `sub`'s `wire sig`; rename edits both files (nested
`u_a.u_b.sig` included); the §2.9-20 warning is retired for a resolved
tail; a generate-scoped net is still refused honestly. Completion after
`u_x.` in an expression lists the hierarchical surface; a connection
list's does not.
Census: single-file numbers unmoved; 12 939 connection + 5 239
hierarchical-only members; 335 corpus references newly resolve, 514 over
opentitan `hw/` (20 sampled by QA, all genuine). 0 of 860 corpus files
differ. Also: §50/§51 planned, §55 (state.rs size) filed.
Co-Authored-By: Claude Fable 5.1 <[email protected]>
TODO §42 (docs/features/lint-config-contract). Closes topo §2.9-28 and
repository-analysis finding 2.
`enabled_rules(settings, project, has_oracle)`: rung 2 is
`lucisv.lint.select` when non-empty else `[lint] select`, rung 5 the same
for `ignore` — the CLI's `pick` applied to the editor — so one buffer
linted two ways is linted the same way (asserted equal over the wire for
three configurations). `lint::project`: `ProjectLint` read from the
`Discovery` result `configured` already computes (no extra read per
pass); an unknown rule name in a project list is dropped and said rather
than silently emptying the selection. `ConfigProblems`/`ProblemLog`:
rejected `[lint.<rule>]` options, unknown names and bad `[lint] waivers`
lines are logged once per (config file, entry) in `lucisv check`'s
wording, re-armed when the config's lint content changes; the buffer
keeps linting with the entry dropped.
Docs applied: README, the linter guide, configuration.md, the analysis,
topo (28 struck; 29 filed for the editor-side unknown-name silence), site
rebuilt.
Co-Authored-By: Claude Fable 5.1 <[email protected]>
TODO §39 (docs/features/waiver-files). Closes §4's last waiver item.
`vlog_linter::waiver_file`: `waive --rule=<rule> [--line=N|N-M]
[--location=<pattern>]`, `#` comments, BOM tolerated; `--location` is
the `--exclude` matcher (`lucisv_core::walk::is_excluded`, a new
vlog_linter → lucisv_core edge), a regex-looking pattern refused by
name. `lint_with(ctx, rules, external)` applies inline and external
waivers as a union and reports which external directives fired;
`lucisv check` reports the dead ones under `unused-waiver` at the
waiver file's line after the whole run. Discovery: `[lint] waivers`
(relative to the toml), `--waiver-file` (repeatable), `lucisv.lint.waivers`
(first workspace root); bad lines fail the CLI run with file:line and
are dropped and logged once by the server.
Review rework (QA's HIGH): the server's code-action path now lints with
the buffer's `LintRun` — its enabled rules and external waivers — so a
quick fix is never offered, nor applied by fix-on-save, for a waived
finding.
Docs: Waivers sections in README and the linter guide, cli and
configuration rows, topo edge, site rebuilt.
Co-Authored-By: Claude Fable 5.1 <[email protected]>
Written by the owner's audit process on 2026-09-04; committed by the lead
unchanged. Findings 1–3 are planned as TODO §41–§43.
Co-Authored-By: Claude Fable 5.1 <[email protected]>
TODO section 35 (54 -> 73 rules: every rule in Verible's published
list but forbid-implicit-declarations).
module-begin-block, legacy-generate-region, legacy-genvar-declaration,
v2001-generate-begin, explicit-function-lifetime,
explicit-task-lifetime (both exempt out-of-body definitions after a
census showed 948 of 960 findings were exactly that shape),
positive-meaning-parameter-name, suggest-parentheses (safe fix,
truth-tabled), unpacked-dimensions-range-ordering, uvm-macro-semicolon,
create-object-name-match, numeric-format-string-style,
macro-string-concatenation, disable-statement, forbidden-macro,
endif-comment (safe fix), forbid-line-continuations, dff-name-style,
proper-parameter-declaration. Verible's forbidden-symbol is the
source-file name of invalid-system-task-function (read in its
rule .cc), so it is that rule's symbols option, nothing fires twice;
void-cast gains forbidden_calls. Shared readers: walk_items_scoped,
exprs.rs, preproc.rs. A checked-in e2e case drives lucisv.lint.options
over the wire. Two rules fire on an error leaf because the parser
refuses a module-scope begin/end and a bare generate begin - filed as
docs/topo.md 2.9-25.
3 695 tests / 48 binaries; corpus 814/820 byte-identical to 0.38.0;
opentitan default-set census 1 053 -> 1 169, the arithmetic balancing
to the six default-on additions; timing unchanged.
docs/features/linter-expansion-3/README.md.
Co-Authored-By: Claude Fable 5 <[email protected]>
TODO section 34 (36 -> 54 rules).
Options: OptionSpec/OptionKind/OptionValue/RuleOptions in vlog_linter
with one validator behind both front ends - [lint.<rule>] tables in
lucisv.toml (accepted now; stored raw by lucisv_core::config, resolved
per file by the CLI with <config>:<line> on the first bad entry) and
the editor's lucisv.lint.options object (bad entries logged and
dropped) - precedence editor > toml > default key by key, --rules-doc
listing every option. A small anchored regex engine of our own: a
Thompson-NFA simulation, linear in pattern x name by construction
(QA's first cut found the backtracking matcher exponential on (a*)*b),
unknown escapes refused by name through both doors, a 71-row table
verified against CPython. The four naming rules take Verible's option
spellings with defaults that keep today's verdicts byte-identical.
Eighteen Style rules, one file each with true positives and near-
misses: line-length (the formatter's width), posix-eof (safe fix),
forbid-consecutive-null-statements (safe fix), generate-label and
generate-label-prefix, package-filename, one-module-per-file (off),
signal/interface/macro/constraint/parameter-type-name-style,
port-name-suffix (off), banned-declared-name-patterns (off),
typedef-enums, typedef-structs-unions (allow_anonymous_nested defaults
true here - opentitan's 3 159 findings were all generated register
packages, and its own config disables the rule), always-comb (unsafe
fix), explicit-begin (off, Verible's eleven enables). Four rules ask
parsed_cleanly() first after a census showed error-recovered UVM files
rebound as generate blocks. package.json regenerated (drift test).
3 549 tests / 48 binaries; corpus 814/820 byte-identical; naming-rule
finding lists identical to 0.36.0; opentitan check timing unchanged.
docs/features/linter-expansion-2/README.md.
Co-Authored-By: Claude Fable 5 <[email protected]>
TODO section 33. Every rule states a Severity (error: would likely fail
to compile or elaborate, or silently mis-synthesize; warning: a probable
bug; style), printed in lucisv check text and JSON, mapped to
ERROR/WARNING/INFORMATION in the editor, grouped in --rules-doc, and
accepted by --select/--ignore and [lint] as a class word. VS Code gains
lucisv.lint.severity.{error,warning,style} and one tri-state
lucisv.lint.rules.<rule> per rule (default/on/off - a client sends
every key, so a boolean cannot say unset), generated by
vlog_linter::vscode with a drift test, and lint::enabled_rules is the
one documented ladder: defaults -> select -> class switches -> per-rule
-> ignore. Nineteen new rules (17 -> 36), one file each with true
positives and near-misses: Error - mismatched-labels,
duplicate-declaration (Semantics::duplicates(), additive),
undeclared-identifier (with a project; silent for macro text, included
fragments, hierarchical tails, any name another file mentions),
unknown-port, unknown-parameter; Warning - forbid-defparam,
invalid-system-task-function, truncated-numeric-literal,
undersized-binary-literal (safe fix), suspicious-semicolon,
packed-dimensions-range-ordering, module-port, module-parameter,
explicit-function-task-parameter-type, plusarg-assignment,
instance-shadowing, forbid-negative-array-dim, void-cast,
incomplete-assignment. Every false-positive class found on opentitan
closed with a named test; 3 383 tests / 48 binaries; corpus 814/820
and byte-identical (formatter untouched); vsix smoke OK.
docs/features/linter-expansion-1/README.md.
Co-Authored-By: Claude Fable 5 <[email protected]>
TODO section 31 (coverage_gaps M9, docs/topo.md 2.9-3).
fence::collect enters class bodies, functions, tasks and always/
initial/final blocks, and statement lists - begin/end, fork/join and
every compound body - through scan_stmt_scope/scan_nested_stmt on the
one scan_units both scope kinds share; stmt_docs/stmt_seq obey the two
swallowed-unit rules item_docs/item_seq had; fence regions merge into
range.rs's plan, which was load-bearing (a fenced statement has no
verbatim run behind it; proved by disabling it). A region opens only at
a line start (opens_line) - the rule the format-fences README has
stated since round 1 - so a fence after code on the same line is an
ordinary comment everywhere, which narrows one accidental item-level
shape (module m; // lucisv: off) and is ruled a drift fix. Deferred
with reasons: port lists, case-item label lists, same-line fences, a
property's locals. verify.rs, lucisv/src/lint.rs and
lucisv_server/src/lint.rs untouched.
Proof: 3 244 tests / 48 binaries, fences.cases 25 -> 38 with the
statement-level entry inverted, corpus 814/820 and 860 files byte-
identical to 0.34.0, opentitan: 4 of its 9 fenced files now keep their
fenced bytes and are fixed points, --check counts identical; 3 348
fence-injection trials with no new refusals.
docs/features/statement-fences/README.md.
Co-Authored-By: Claude Fable 5 <[email protected]>
Committed by the lead as found on 2026-09-02 so lane merges can proceed;
content reviewed (README claims match delivered features).
Co-Authored-By: Claude Fable 5 <[email protected]>
The hand-patched diagnostic build becomes a feature: --verbose gates
the timing lines (request answered / notification handled / HELD
behind a rescan / scan and widen lifecycle / flush / reindex_one, the
exact wordings of the two diagnostic builds) as LOG messages into the
client's output channel; without the flag not one line is sent and
the cost is one branch, measured unmeasurable against HEAD. Unknown
args exit 2 with usage before the transport opens. The extension
gains lucisv.verbose (default off) and its first restart-on-settings
machinery: restart.js, one serialized chain reconciling to the last
toggle, no client transition outside it — activation and deactivate
included — after QA twice caught the alternatives (a mid-start toggle
silently rejoining the stale start; deactivate's out-of-chain stop
orphaning a spawn). Headless node harness restart_test.js, 44 checks,
five mutations caught. Spawn contract amended everywhere it is
written: no args required, --verbose optional.
Co-Authored-By: Claude Fable 5 <[email protected]>
A 7th package, lucisv-<v>-all.vsix, carries every platform's binary
pair under bin/<platform>-<arch>/ and the extension picks the right one
at runtime — flat bin/ (platform package) first, then the platform-arch
subdirectory, then PATH. Target-less on purpose, so Alpine and anything
else vsce refuses to name gets working static binaries. The release.yml
inline prune step moves into tools/prune_release_assets.sh, which now
requires all seven packages by name before anything is published.
Co-Authored-By: Claude Fable 5 <[email protected]>
Owner decision: the release page carries the .vsix packages (each
platform package checked by name — a missing one fails the release —
plus the universal fallback) and SHA256SUMS, nothing else. The loose
binaries are still built and audited on the runner, since the packages
embed them, but no longer attached; standalone binaries are a cargo
build away. The new workflow step prunes dist/ after the audit and
filters SHA256SUMS to the packages, keeping the audited hashes, then
re-verifies. Prune logic tested against the real 0.10.0 dist with a
missing-package negative control; docs trued up in RELEASING.md, the
top-level README and both feature READMEs.
Co-Authored-By: Claude Fable 5 <[email protected]>
The v0.7.1 release made three claims false: 'there are no prebuilt
downloads' (the releases page now has five platforms + the .vsix per
tag), 'the script builds for the host triple only' (--cross has existed
since 0.7.0's cross-platform release), and the hardcoded
lucisv-0.5.0.vsix example. The bigger correction: the 'server does not
read lucisv.toml yet' caveat has been stale since the config ladder
landed in lucisv_server/src/format.rs -- replaced with the actual
precedence (lucisv.toml > lucisv.* settings > tab size > default). Also
states plainly that Linux/Windows artifacts are audited, not executed.
.DS_Store untracked and gitignored.
Co-Authored-By: Claude Fable 5 <[email protected]>
Hovering `NAME(args) now appends an expands-to section: the definition
the card already chose (single_step is blind to lookup, so they cannot
disagree) with parameters substituted by the call's arguments - one
step, so nested macro names stay as written. Strings, `" markers and
escaped identifiers are never substituted into; count mismatches,
unnarrowed multiple candidates and paren-less function-like uses get no
section rather than a guess; an empty argument takes the parameter's
declared default. 2000-char cap with a note. Version 0.5.0 closes the
M7-M14 navigation run with a CHANGELOG entry covering all eight.
Co-Authored-By: Claude Fable 5 <[email protected]>
The -f flag (repeatable) feeds M1's filelist parser to format, check,
--check and --diff: listed paths are exact like positional args (never
excluded or gitignored), warnings go to stderr without touching the
frozen exit-code contract, an unreadable filelist is exit 2 with nothing
written, and inputs from every source dedup by lexical absolute path -
which also closes the old vfmt rtl/ rtl/a.sv double-processing. --lines
and stdin reject -f at parse time. vfmt.toml's filelist key stays
server-only, deliberately. QA's exit-code matrix confirmed all eight
cells; its pre-existing torn-write find is filed in TODO §1.
Co-Authored-By: Claude Fable 5 <[email protected]>
The first rules that use vlog_semantic, crossing TODO §7's threshold the
careful way: a read/write/unknown classification layer in vlog_linter
(vlog_semantic untouched - driver semantics is a lint concept), whole-
word mention guards so ifdef arms and macro bodies never produce a false
unused, connections treated as unknown direction, and force/release with
their own driver kind so a test override is neither a second driver nor
the only one. All three default off, decided from data: 55 corpus hits,
zero wrong on reading, but single-file scanning cannot see cross-file
readers. Default vfmt check output is byte-identical to before,
worktree-diffed. ~45ms per 860 files when enabled; three rules cost one.
Co-Authored-By: Claude Fable 5 <[email protected]>
VS Code's built-in default colour provider (editor.defaultColorDecorators,
default auto since 1.78) pattern-matches CSS-style hex in languages where
no extension provides document colours - so delay controls like #200 grew
RGB swatches. The extension now ships the language-scoped configuration
default "never" for [verilog] and [systemverilog]; user-overridable,
invisible to every other language. Diagnosis verified on the reporting
machine: no colour-provider extension installed, no server capability, no
user override.
Co-Authored-By: Claude Fable 5 <[email protected]>
Hover cards fence their declaration snippets as systemverilog markdown,
but VS Code colors fences with a TextMate grammar and the extension
deliberately shipped none - so hovers rendered plain. One compact
lookaround-free grammar (comments, strings closing at end of line, based
and fill and real and time literals, directives then macro uses, system
tasks, all 181 keywords generated from vlog_parser::KEYWORDS with a
mutation-checked drift test) registered for both language ids. Buffers
also gain colors before the server starts; semantic tokens still win once
it does. Fence tags are pinned as a contract in hover and completion.
Co-Authored-By: Claude Fable 5 <[email protected]>
A template tier between index names and keywords: if / if-else / else-if
(gated on the line head, so it appears after end but not after an
identifier), case and casez with default, loops, always_ff (plain and
reset variants), always_comb, always @(...), initial, and declaration
templates - logic/localparam/parameter in .sv, wire/reg/integer twins in
.v; pathless buffers get the conservative Verilog set. One renderer
spells each body as snippet and plain text so the two cannot drift, and a
registry-wide test parses every untouched expansion. Nine overlapping
static VS Code snippets moved server-side; file-level ones stay static.
Co-Authored-By: Claude Fable 5 <[email protected]>
The rainbow painted depth 3-5 pairs with editorBracketHighlight
.foreground4..6, whose VS Code defaults are fully transparent — a begin
typed three levels deep vanished with its end. The extension now uses
contributed vfmt.rainbow1..6 colors with opaque defaults in every theme
variant (dark/light/HC/HC-light), and vfmt/scopePairs additionally
reports genuinely unmatched begin/end/fork/join tokens, painted
vfmt.rainbowUnmatched bright red — file characters are never hidden.
Matched pairs, depths and 78eeef6's counting are unchanged.
Co-Authored-By: Claude Fable 5 <[email protected]>
Five completion tiers in one response: module skeletons (M4, unchanged
gate), scope-visible symbols with real kinds, workspace-index names and
`define macros (backtick-aware, never inventing punctuation), Verilog/SV
keywords (single-source KEYWORDS list factored from the lexer's table,
lexing unchanged), and token-harvested project words — comments and
strings contribute nothing and get no completions. Candidate tables build
with the index over the M1 scope ladder (94 ms / 860 files, ~1.4 MiB);
a keystroke answers in ~300 µs, budget-tested. Version 0.3.0 across the
workspace and extension, CHANGELOG covers the M1-M5 refactoring layer.
Co-Authored-By: Claude Fable 5 <[email protected]>
Rope-port umbrella plan (docs/features/refactor) + TODO.md §8; M1 ships
vfmt_core::filelist (-f nesting with cycle + 256-depth guard, +incdir+/
+define+ recorded, env vars, warnings not errors), the vfmt.toml filelist
key, the server scope ladder (filelist > workspace walk > open file's
directory when rootless) and the vfmt.filelist VS Code setting.
Co-Authored-By: Claude Fable 5 <[email protected]>
printer::fits() now measures from a multi-line Doc::Inline's last line and
keeps measuring the rest of the group (a with {...} block no longer hides
an overflow). skip_action_stmt tracks begin/end, fork/join, case/endcase
nesting so a concurrent assertion's action block is captured whole.
Comments between bind/target/module and around randomize(...) with are
attached and reprinted instead of being refused by the safety net.
All 800 passing corpus files format byte-identically before and after.
Co-Authored-By: Claude Fable 5 <[email protected]>
A macro invocation that ends its line is a complete item whatever opens
the next line; new <expr> shallow-copy constructor; a based number whose
digits come from a macro (32'h`BOOT_ADDR) lexes as a base-only number
joined with the macro in the parser. verify.rs untouched, attack tests added.
Coverage loop round 2: 796 -> 800 / 820 (97.1% -> 97.6%).
Feature README: docs/features/mop-up-2/README.md
Co-Authored-By: Claude Fable 5 <[email protected]>
randomize()/std::randomize() with { ... } (block verbatim), array-method
with (expr), foreach over scoped/hierarchical/indexed arrays, randcase,
wait fork, import as a statement, let declarations, empty call arguments,
general statement labels, and endtask: name; (stray semicolon kept).
Also fixes a pre-existing verification failure for a comment between a
then-branch and its else.
Coverage loop round 1, cluster 8: 772 -> 796 / 820 (94.1% -> 97.1%).
Feature README: docs/features/dv-statements/README.md
Co-Authored-By: Claude Fable 5 <[email protected]>
Anonymous enum/struct/union declarations, struct packed as a parameter type default, user_t [N:0] x; at item and statement position, typedef enum with a typedef'd base, nested anonymous structs, localparam type as a body item, multi-declaration for-loop inits.
Coverage loop round 1, cluster 6: 740 -> 751 / 820 (90.2% -> 91.6%).
Feature README: docs/features/types-decls/README.md
Co-Authored-By: Claude Fable 5 <[email protected]>
interface...endinterface shares the module header/body machinery (ItemKind::Module with kw == "interface"); modport and clocking are structural items; virtual <iface>[#(...)] is accepted in every type position. module-filename now applies to interfaces.
Coverage loop round 1, cluster 5: 712 -> 740 / 820 (86.8% -> 90.2%).
Feature README: docs/features/interfaces/README.md
Co-Authored-By: Claude Fable 5 <[email protected]>
Macro invocations with whitespace before the argument list, a bare macro on its own line followed by a declaration, `error/`warning directives, and $error/$fatal/$warning/$info as module/generate items.
Coverage loop round 1, cluster 1: 636 -> 661 / 820 (77.6% -> 80.6%).
Feature README: docs/features/item-misc/README.md
Co-Authored-By: Claude Fable 5 <[email protected]>
dynamic-types: queues ($ as an expression primary -- one grammar
addition and [$], [$:N], q[$-1] all fall out of existing machinery),
dynamic [] and wildcard [*] dims (DimKind, the round's one
non-additive AST change: three consumers, all updated), empty {}
literals, named call arguments f(.a(x)) as ExprKind::NamedArg,
case ... inside with range labels, bare @event sensitivities (also
fixing a pre-existing invented-parens refusal), and macro items
before ident-dot statements. Everything structural, nothing
verbatim; verify.rs and fence.rs byte-identical. Corpus 578 ->
636/820 formattable (70.5% -> 77.6%), parse-error 242 -> 184, 58
gained / 0 lost by path, all 636 round-tripped, all 578 previously-
formattable files byte-compared old-vs-new with zero differences.
Two newly-reachable comment drops fixed in-round (one pre-existing,
one this round's own new code -- split documented honestly post-QA).
New top blockers: interface (25), the `else head-swap (13).
one-parse: LintContext::from_parse accepts pre-built parse products
(Backing enum forced by SourceFile: !Clone; new() stays a one-line
wrapper -- all 12 rule files byte-untouched); ParsedSource::parse
lexes once; vfmt check parses once per file; the server lints from
Document's own products, eliminating the per-keystroke second parse.
Behavior identity proven at the byte level (2.4MB corpus JSON, 13
server publishes, corpus-wide --fix); check --threads 1 20% faster,
server didChange latency roughly halved. protected_regions left
alone per its documented anti-drift signature. Lead fixes on
acceptance: the from_parse contract-cost doc sentence, and a stale-
tree guard test in the server (QA's sabotage passed all 773 tests --
nothing pinned text/tree agreement; now one test does, through the
merged diagnostics path where the stale warning actually lives).
791 workspace tests. Dev: 2 Fable agents; QA: 2 Opus agents; reviews
in docs/features/{dynamic-types,one-parse}/README.md.
Co-Authored-By: Claude Fable 5 <[email protected]>
range-formatting: --lines M-N[,M-N...] formats only the top-level
items intersecting the ranges; modules/packages split head/body/tail
with independent decisions, everything else is atomic, and
unselected units are emitted as merged verbatim source slices (the
run-merge is load-bearing: per-item slices let separators collapse
blank lines between untouched items). Convergence via Selection
replay -- same-selection re-runs are fixed points, sound because the
equivalence check has already proven token identity; QA's sabotage
of the replay failed immediately on real RTL. The honest limit
(same line numbers can sweep in a neighbor after lines move;
449/8236 corpus trials, all settled next run) is measured and
pinned. Fence wins over range; alignment groups split at verbatim
boundaries; cache fully bypassed; LSP rangeFormatting advertised and
consumes only lines (no UTF-16 column math); tools/vfmt-changed.sh
derives ranges from git diff. Default behavior provably unchanged
(TSV md5 + all-578-file byte-compare vs a pre-round binary).
lint-rules-2: visit.rs walks class bodies (closing the classes
handshake; +6 real findings in UVM code), five new rules with
evidence-based defaults -- parameter/enum/struct-union-name-style ON
with Verible's exact names and published defaults (vendored waivers
now honored), module-name-style OFF (Verible has no such rule; the
brief's premise was checked and corrected), wire-reg-mixup ON (0
corpus noise in .v, 209 findings on a .sv rename -- both zeroes
proven). rules_markdown() generates the rule reference; 13 rules
total, zero CLI/server wiring needed.
Also: lead notes in classes and shared-fence-filter READMEs
documenting the fence asymmetry lint-rules-2 QA found (a fence in a
class body protects fixes via the scan backstop even though the
formatter ignores it there).
768 workspace tests. Dev: 2 Opus agents; QA: 2 Sonnet agents;
reviews in docs/features/{range-formatting,lint-rules-2}/README.md.
Co-Authored-By: Claude Fable 5 <[email protected]>
alignment: Verible-style alignment-intent inference for ANSI ports
(name column), named connections (paren column) and parameter items
(name and = columns). A group aligns iff the author asked: >=4
excess spaces somewhere, or the group already sits consistently at
one column -- single-space code keeps today's bytes exactly (zero
churn across all 397 pre-existing cases; corpus outcome TSV
byte-identical while 291/578 formattable files change content).
Fixed-point by construction: aligned output re-infers the same
targets, flush re-infers flush; the whole verdict is decided at
document-build time (a printer-side split diverged ibex_core.sv at
width 60 during development -- caught by a 2312-run config sweep and
redesigned). Groups break at comments/attributes/directives/blank
lines; a group that cannot fit falls back to flush whole, never
mixed. No lexer changes: name_span plus the source answers every
spacing question. QA's sabotage confirmed the runtime convergence
check catches the predicted flip-flop even with the unit test gone.
format-cache: warm runs skip verified-clean files. Key = (FNV-1a 64
content hash, resolved config values, vfmt version), path-keyed;
only the fixed-point verdict is ever cached, so --check/--diff can
never go stale and a hit can only skip work, never produce output.
One atomic text file in self-gitignoring .vfmt_cache/; --no-cache /
--cache-dir; 8-process concurrency clean. Warm corpus check: 2x at
default threads, 7.7x single-threaded.
655 workspace tests. Dev: 2 Opus agents (both isolated their gates
from the other's churn via HEAD-reverted scratchpad copies); QA: 2
Sonnet agents; reviews in docs/features/{alignment,format-cache}/
README.md.
Co-Authored-By: Claude Fable 5 <[email protected]>
The top corpus blocker (142 extends-blocked UVM/DV files) falls.
Structural support: class/virtual class with parameter ports,
extends (named/ordered params), implements, property qualifiers
(rand/randc/local/protected/static/const), virtual interface
properties, parameterized types, method qualifiers with extern and
pure-virtual prototypes plus out-of-body cls::method definitions,
typedef class, scoped parameterized calls, disable fork. Class
bodies reuse the existing item loop, so Meta, directives, macros and
nesting work with no per-site code. Constraint blocks, covergroups
and parameterized-type #() arguments are span-sliced verbatim leaves
-- their internals are a distinct sub-language where formatting has
no payoff and corruption risk is highest, so 9 masked-corruption
rejection tests ship although verify.rs is byte-identical
(invariant-4 discipline, voluntarily; QA's sabotage recreated the
historical in-string corruption and exactly one pin turned red).
Corpus: 476 -> 578/820 formattable (70.5%), parse-error 344 -> 242,
zero regressions by path, all 578 formattable files round-tripped
individually. 72 of the 142 extends files format; 70 advance to
named next blockers -- queues/dynamic arrays are now the top corpus
blocker (41 files). Two verification failures fixed en route: a
pre-existing lexer blank-line-after-continuation bug (proven
pre-existing on a HEAD worktree) and raw_inline convergence for
mid-line verbatim starts.
Handshakes filed: fences inactive inside class bodies; the four
AST-walking lint rules skip class members (line-based rules still
fire); vlog_semantic treats class bodies as opaque -- the LSP
navigation gap is that crate's natural next round. parse() now takes
the source (verbatim capture in strict mode); single caller updated.
612 workspace tests (397 cases). Dev: Opus agent; QA: Sonnet agent
(pre-feature worktree diff, full 578-file round-trip, UVM torture,
two reverted sabotages); review in docs/features/classes/README.md.
Co-Authored-By: Claude Fable 5 <[email protected]>
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]>