Index admitted mixed typed source without losing bundle authority
This commit is contained in:
@@ -0,0 +1,51 @@
|
||||
# Private mixed typed occurrence index
|
||||
|
||||
Source checkpoint on `codex/analysis-mixed-index-956atf-20260924`, based on
|
||||
`aaec78fcc9b273d1485497126392afdd1fb2e54e`. This records implemented structure;
|
||||
compilation and runtime acceptance have not yet occurred at this checkpoint.
|
||||
The accepted contract/review are published at
|
||||
`7cfdd13d3a1472e63fd34b0080b2cfc4b921b23e:harness/analysis-mixed-index-contract-20260924.md`.
|
||||
Independent exhaustive fixture data and its raw-byte checker are at
|
||||
`ae6df4fa1f103ff9b14963731b2edd84e38738b1:harness/analysis-mixed-index-20260924/`.
|
||||
|
||||
`ResolvedMixedProject::index` consumes the sealed complete-Project witness.
|
||||
`IndexedMixedProject` owns it and shared `IndexData`; read-only methods expose
|
||||
the Project, warnings, original bundle/canonical files, names and typed maps.
|
||||
It has no conversion to the legacy numeric-source Index or its updater. The
|
||||
constructor-only adapter keeps its file table private, so shared verification
|
||||
does not accept caller-fabricated mixed source/token ownership.
|
||||
|
||||
Shared verification preserves original token, owner, structural child-path,
|
||||
qualified call-label and physical occurrence checks. Mixed catalog construction
|
||||
streams complete Project globals and scoped parameters once. It does not
|
||||
reparse, relower, duplicate model records or repeat admission. Ordinary globals
|
||||
are names/targets here; ordinary source occurrences are not indexed by this view.
|
||||
Complete non-expression occurrence emission remains the sealed lowerer's
|
||||
invariant, checked by an independent exhaustive output oracle.
|
||||
|
||||
Mixed allocations reserve against the retained aggregate ledger before growth.
|
||||
New map/vector/set/Path entries charge entry slots; retained raw lowerer
|
||||
occurrences keep occurrence slots. New names charge copied UTF-8 bytes. Owner
|
||||
and physical-token scratch drop after occurrence checks; path/call scratch drop
|
||||
before syntax-edge traversal. Shared Path nodes remain retained while map keys
|
||||
own them. Legacy typed-only construction retains its original local policy.
|
||||
|
||||
Precompile independent review found stale diagnostic file attribution in two
|
||||
late verification loops and unsafe fallback for invalid file/UTF-8 spans. The
|
||||
source now updates attribution for each checked record and maps invalid
|
||||
locations explicitly to a safe start span, retaining a valid file when known.
|
||||
Regression cases are authored; no passing runtime result is implied.
|
||||
|
||||
Seven new tests cover complete OA/SA names/maps/model and Unicode/CRLF variants,
|
||||
qualified corruption cases, inherited-plus-new storage and copied-name byte
|
||||
boundaries, original provenance/admission metadata, and small-stack success and
|
||||
late rejection. Existing rich fixture/model construction is factored without
|
||||
removing its original full arena test. Actual test inventory, strict core lint,
|
||||
focused checks, full private-library dispositions and formatting still require
|
||||
current-source execution. Prior private source8 failures are not suppressed.
|
||||
|
||||
The working agreement is synchronized to current main blob
|
||||
`e76647f49913b314e1543c4464f6199533909bae`. This source remains separate from the
|
||||
Windows prerelease. Public source8, ordinary occurrence composition, source
|
||||
updates/output admission, migration, checked save/history, GUI and API parity
|
||||
remain required subsequent work.
|
||||
Reference in New Issue
Block a user