Native VBS and CMake builds of the server and every registered suite: protocol and document sync, VBS/compdb providers, stock GCC diagnostics (including in-process default profile preparation), the stock occurrence observer and hover/definition, the bounded Scheduler, C++ module graph, scan and artifact cache with real CMI production, the context-aware symbol index with schema-2 snapshot migration, navigation and guarded rename, reflection provenance with splice-origin extraction, index-backed completion and signature help, live GCC worker control with a registered DAP suite, and the Neovim and VS Code clients. VoidLibrary follows main. The private GCC 16.2.0 frontend is reproduced from the versioned patches and verified stepping reflection/template code with projected values 17/34 and 41/82.
38 lines
3.3 KiB
Markdown
38 lines
3.3 KiB
Markdown
# 14 — Completion, signatures and hover
|
|
|
|
Status: PARTIAL; index-backed `textDocument/completion` and `textDocument/signatureHelp` from the compiler-provided occurrence signature (bounded core, server wiring and registered `vls_feature_tests`) are implemented. Compiler-native completion, visibility proof, deferred detail resolution and signature help for overloads beyond the selected occurrence remain open.
|
|
Requirements: R-011,R-013,R-014
|
|
Dependencies: 03,05,09,10,12;15 supplies workspace candidates after its contract freezes.
|
|
|
|
## Ownership and boundaries
|
|
Proposed Sol feature adapters; Astra handles compiler-semantic blockers. NEW src/features/completion/, src/features/hover/, tests/completion/, tests/hover/.
|
|
Future assignments must verify the then-current baseline and exact disjoint paths;
|
|
these proposed scopes do not authorize work in another repository.
|
|
|
|
## Contracts and data flow
|
|
Completion queries use a position within one immutable document/context and return compiler-proven candidates with replacement ranges, type/signature and provenance. Hover reflects the selected semantic entity/type/value. Workspace index suggestions must be validated against visibility/context rather than treated as binding authority.
|
|
|
|
## Implementation sequence
|
|
1. Support compiler-native recovery/completion at incomplete expressions, scopes, templates, imports and reflection/splice sites. Preserve the client request position encoding.
|
|
2. Rank and filter candidates by semantic accessibility, active context, locality and deterministic relevance. Avoid a keyword-only substitute for reflection-generated members.
|
|
3. Implement documentation/signature/value rendering and deferred completion detail resolution tied to the original candidate identity; bound content and escape editor rendering.
|
|
4. Measure warm/cold operations on the real corpus, retain warmed compiler state under10's budget, and keep auto-import edits outside initial scope unless separately contracted.
|
|
|
|
## Failure behavior and constraints
|
|
Cancelled/stale resolution returns a typed cancelled/stale result rather than details for a different entity. Backend-incomplete states remain visible. Never expose inaccessible module symbols merely because the index contains them.
|
|
|
|
## Acceptance scenarios
|
|
1. Cover member/scope/template completion, dependent/invalid expressions, reflected/generated members and imported visibility.
|
|
2. Validate Unicode replacement ranges, stable resolution identities, overload/signature hover and bounded huge values/docs.
|
|
3. Benchmark warm completion p95 near100ms and hover responsiveness with concurrent background/index/debug work; record hardware and misses.
|
|
|
|
## Verification and integration
|
|
Proposed NEW CTest label: `completion-hover`. Once implemented, register a nonzero suite and run:
|
|
```sh
|
|
dev cpp-gcc -c ctest --test-dir build/bootstrap -L completion-hover --output-on-failure
|
|
```
|
|
This future command is not evidence that the label/tests exist now. Before dispatch,
|
|
bind the fixtures above to actual targets and record prerequisites/side effects.
|
|
Require fresh independent review of the implemented contract and affected integrations.
|
|
Disable optional ranking/detail features while preserving correct compiler candidates. Cache format/identity changes invalidate entries; no stale hover/candidate references survive backend replacement.
|