cli: inspect anonymous source properties iteratively

This commit is contained in:
dev committed 2026-10-10 13:30:10 +03:00
1 parent b23f3e678e
commit 53907ecf25
4 files changed
+194 -7

No files matched your search

+8
View File
@@ -140,3 +140,11 @@ The 16,384-array source again aborts before this increment at 24a3876: the fresh
Tests compare 1,736 shallow leaf/array/wrapper combinations against the independent pre-repair derivation, including unknown names/constructors, array boundary lengths and competing error priority. A 32,768-level mixed annotation is constructed and inspected iteratively; unknown and nonvalue leaves retain their original diagnostics. Every allocator request is failed in turn, with arena cleanup checked. Type-position and Copy-content CLI integration pass 74 and 119 checks. All units and format checks pass. All 1,791 conformance cases pass with exact corpus coverage; all 1,421 public source checks and 506 accepted lowerings retain byte-identical old/new exit/stdout/stderr.
Complete checking still accepts the 4,096-array input. At 16,384 it now passes resolveType and aborts in type_properties.firstInvalid (10,001 symbolized frames, exit -6 and no diagnostic JSON). Only child core capture is disabled; no timeout ends a probe. Recursive diagnostic type text and other source property/query paths remain audit candidates. This is not arbitrary-depth source acceptance: Q-059, Q-060's closing validation and Phase 6 gates remain open. Claude's previous nominal-property review covers neither this increment nor the generic-use repair.
## Source anonymous property scans
At b23f3e6, the ordinary 16,384-array source aborts in type_properties.firstInvalid (10,001 frames). A second source wraps the same array annotation in own_array; it aborts in linear (7,060 frames). Both exit -6 without diagnostic JSON. The repair makes firstInvalid follow array/wrapper syntax with constant traversal state, preserving outer-before-inner own_array checks and the island/frozen/arc stop. Its known-linearity helper peels only anonymous array chains; named declaration lookup, parameter binding/shadowing, memo generations, cyclic paths and fixed-point retries retain their original algorithm. No new allocation or error conversion is introduced by either loop.
Tests compare 2,160 shallow cases against the independent pre-repair anonymous traversal, including nominal/generic content, cycles with a positive witness, unknown parameters, parameter shadowing, nested own_array and graph stops; the nominal declaration algorithm is shared, not an independent nominal oracle. Deep array/mixed-wrapper queries cover 32,768 levels, positive/negative content and original failure spans, while an allocator failing at its first request verifies zero work allocations on these anonymous paths. Existing diamond/cycle tests, all units and format checks pass. Copy-content/generic CLI integration passes 119/32 checks; all 1,421 public source checks and 506 accepted lowerings retain exact old/new exit/stdout/stderr. All 1,791 conformance cases pass with exact corpus coverage.
Both previously aborting complete 16,384-level checks now accept without output, as does the 4,096-array input. Non-Copy content behind the deep own_array returns exactly one E7005 at 2:19, with constraint Copy and type_constructor own_array. Core capture alone is disabled and no timeout ends a probe. These process outcomes establish repairs for these inputs, not arbitrary-depth source acceptance. A separate 8,192-declaration source probe confirms remaining native recursion through named source types: before this repair, 3,326 linear and 3,325 declaration frames; afterward, 3,306 and 3,305, both exit -6 without diagnostic JSON. Source Ty equality/text/AIR conversion and other closing call paths also remain to audit. Q-059 and Phase 6 gates remain open; Q-060's full per-step validation remains separate. No syntax/feature/code/bundle growth, runtime/effect/ownership rule or acceptance limit changes. No fresh Claude review is claimed.
+2
View File
@@ -481,6 +481,8 @@ The [source generic-use increment](air-type-depth-audit.md#source-generic-use-de
The [source annotation resolution increment](air-type-depth-audit.md#source-annotation-resolution) replaces recursive source-to-Ty construction with explicit continuations while preserving pre/post checks and error positions. Deep isolated resolution succeeds; complete checking exposes the next confirmed failure in type_properties.firstInvalid. Source property traversal, diagnostic text and closing call-path checks remain open; no universal source depth limit is added.
The [source anonymous property increment](air-type-depth-audit.md#source-anonymous-property-scans) removes confirmed recursion from firstInvalid and the array-chain portion of known linearity. Both 16,384-array and own_array checks now accept, while non-Copy content retains E7005 at its original span. A separate 8,192-declaration probe confirms remaining linear/declaration native-stack exhaustion before and after this increment. Named-declaration repair and source Ty/query closing checks remain open; no acceptance limit or semantic rule changes.
## Q-060 — Native recursion while materializing runtime values
The [executed runtime audit](runtime-value-depth-audit.md) confirms that a verified one-byte value with 32,768 length-one nested arrays aborts inside zeroValue under `aji run --fuel 8`, rather than producing a run record. The instruction has not exhausted fuel. Iterative runtime traversal must preserve initialization, value shape, allocator/root lifetimes, collection safety and instruction accounting; adding a depth trap/acceptance limit needs a normative decision. At that baseline, recursive copying, value sizing, collection and serialization were additional audit candidates with unverified failure paths; the increment below records subsequent executed failures. Compiler type repairs in Q-059 do not resolve Q-060.
+6
View File
@@ -466,3 +466,9 @@ Units/format checks and generic/static-function CLI integration (32/25) pass. Al
The [Q-059 annotation-resolution increment](../design/air-type-depth-audit.md#source-annotation-resolution) lowers anonymous source types with explicit continuations. Constructor-before-child and content-after-child checks preserve the old error priority and spans; nominal identity and syntax are unchanged. Tests cover 1,736 independent shallow comparisons, 32,768 mixed annotation levels, leaf rejection and allocation-error cleanup. Type-position/Copy-content integration passes 74/119 checks; all units/format checks and 1,791 conformance cases pass with exact corpus coverage. All 1,421 public source checks and 506 accepted lowerings retain byte-identical old/new exit/stdout/stderr.
The complete 4,096-array check still accepts; 16,384 now reaches the next confirmed native-stack failure in type_properties.firstInvalid. No normative/bundle/feature/code change or accepted-depth limit is introduced. Q-059's source property/closing audit, Q-060's closing validation and Phase 6 gates remain open. No fresh Claude review of this increment is claimed.
## Source anonymous property scans (2026-10-10)
The [Q-059 source-property increment](../design/air-type-depth-audit.md#source-anonymous-property-scans) makes syntax scanning and anonymous-array linearity iterative, retaining own_array priority, graph stops and nominal fixed points. The two complete 16,384-level source checks that previously aborted now accept; deep non-Copy content returns the original E7005. Tests cover 2,160 independent shallow anonymous comparisons, 32,768-level queries and zero work allocations on anonymous paths.
Units/format checks, Copy-content/generic CLI integration (119/32) and byte-identical old/new checks/lowerings (1,421/506) pass; all 1,791 conformance cases pass with exact corpus coverage. A separate 8,192-declaration source confirms the remaining linear/declaration stack failure before and after this increment. Named-source repair, source Ty/query closing checks, Q-060 validation and Phase 6 gates remain open. No normative/bundle/feature/code change or accepted-depth limit is introduced; no fresh Claude review is claimed.