Refactoring M5: keyword + project-wide identifier completion; v0.3.0

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]>
This commit is contained in:
lucioandClaude Fable 5 committed 2026-08-24 15:07:57 -07:00
1 parent 78ba0b8ba6
commit d8e37086df
18 files changed
+2281 -320

No files matched your search

+19 -1
View File
@@ -96,6 +96,18 @@ the work is reviewed**. Owner-priority items first (2026-08-24).
- [ ] Declare-missing-signals companion action (generate `logic` decls for
unconnected skeleton ports) — backlog
### Completion (owner request, 2026-08-24 evening)
- [x] **Keyword completion** — Verilog/SV keywords offered as completion
items alongside everything else → `docs/features/completion-core/README.md` (M5)
- [x] **Project-wide identifier completion** — names visible in the current
scope (semantics-ranked first) plus identifiers used anywhere in the
project scope (filelist, else workspace walk, else same-directory —
M1's ladder), harvested from *tokens* so comments and strings never
contribute candidates; no completions offered while typing inside a
comment or string → M5
- [x] **Version 0.3.0** — workspace + extension bump with a CHANGELOG entry
covering the whole refactoring layer (M1–M5) → M5
### Structural refactorings (backlog, post-M4)
- [ ] **Extract module** from a selected statement range (infer ports from
read/driven sets) — the flagship, hardest one
@@ -108,6 +120,8 @@ the work is reviewed**. Owner-priority items first (2026-08-24).
`wire-reg-mixup` lint rule's fix slot)
- [ ] **Move typedef/function/localparam into a package**; update imports
- [ ] **Organize imports** (sort, dedupe, drop unused)
- [ ] **Completion for preprocessor directive words** (`` `ifdef`` …) and
suppressing self-instantiation skeletons — two LOW QA finds from M5
- [ ] **Rename module together with its file** (`module-filename` rule
agreement; needs LSP `workspace/willRenameFiles` plumbing)
@@ -169,6 +183,9 @@ commit — in order:
all instantiations, exposed as code actions + `workspace/executeCommand`.
4. **M4 `refactor-instantiate`** — instantiation completion snippets,
auto-connect, signature help in connection lists.
5. **M5 `completion-core`** — keyword + project-wide identifier completion
(token-harvested, comment/string-free), merged with M4's module
snippets; version bump to 0.3.0.
5. **Backlog** — the unchecked structural items above, re-planned when the
first four have soaked.
@@ -180,7 +197,8 @@ commit — in order:
- [x] M2 refactor-rename — done, QA clean after one rework round, reviewed
- [x] M3 refactor-ports — done, QA clean after one rework round, reviewed
- [x] M4 refactor-instantiate — done, QA clean after one rework round, reviewed
- [ ] Backlog triage after M4
- [x] M5 completion-core — done, QA clean first pass, reviewed
- [ ] Backlog triage after M5
## Work log