Consume a compiler-agnostic completion index

Under D-032, completion can now merge candidates from a documented,
versioned index file produced by any external tool. The bounded core
parses and selects the innermost covering scope, the server puts its
items ahead of index-backed ones and takes isIncomplete from the
scope's complete flag, and registered feature tests cover parsing,
selection and bounds. A real stdio session returned the provided
items first with isIncomplete false inside the scope and true outside.
This commit is contained in:
faumaray committed 2026-12-06 02:10:16 +03:00
1 parent 236c3c5718
commit 4a029152e9
13 files changed
+336 -11

No files matched your search

+19
View File
@@ -61,6 +61,25 @@ start coordinate only, so ranges are zero-width until an end is available.
LSP adapters and index/rename/debugging integration remain open. `vbs test`
passed all 17 native suites; CMake passed the reflection and trace suites.
## December 6 compiler-agnostic completion source
Per D-032, completion can now consume a documented, compiler-agnostic index
(`--completion-index PATH`) produced by any external tool:
`{"schema":1,"scopes":[{"path","startLine","startCharacter","endLine",
"endCharacter","complete","items":[{"label","kind?","detail?","insertText?"}]}]}`
with the producer's visibility claim carried through unchanged. The bounded
core (`vls/features/CompletionSource.hpp`) parses and selects the innermost
covering scope; the server merges its candidates ahead of index-backed ones and
sets `isIncomplete` from the scope's `complete` flag. Registered
`vls_feature_tests` grew to 115 cases.
Real stdio session:
```
inside scope: isIncomplete = False items = ['alpha', 'beta', 'main']
outside scope: isIncomplete = True
```
All 18 native suites and all 18 CMake tests passed.
## December 6 locality ranking in completion
Completion candidates now carry whether they are declared in the requesting