feat(resolver): expose portable executable program IR - #282
Open
levi770 wants to merge 1 commit into
Open
Conversation
levi770
force-pushed
the
codex/structured-source-inventory
branch
from
August 31, 2026 19:26
02272cb to
44c59a4
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
Downstream consumers currently have to reconstruct executable XLOG semantics from source text or from process-local AST details. That duplicates frontend/resolver logic, loses exact import-selection provenance, and cannot safely carry interned symbol identifiers across a process boundary.
Implementation
ModuleResolver::resolved_program_extraction(source_root)as the production structured extraction boundary.ProgramMergeReport, recording only declarations and clauses actually admitted after private/selective filtering and deduplication. Provenance therefore follows the real merge operation, not textual equality heuristics.xlog extract --source-root ... <entry>for end-to-end resolver-to-JSON execution. Existingxlog manifestremains available for the source-only view.ModuleResolverso source provenance cannot silently drift between parse and extraction.ParserSession::split_statementsso the valid univ operator=..is not split at either dot.Behavioral evidence
xlogprocess, parse its JSON, inspect executable rules and query relations, and verify source-root rejection.Verification
On rebased commit
44c59a4a571aa2b33872401b59e9ec86d2b38774:cargo fmt --all -- --checkcargo clippy -p xlog-logic -p xlog-cli --all-targets -- -D warningscargo test -p xlog-logic --test resolved_program_extraction --test resolved_program_manifest --test test_v085_incremental_parse -- --nocapture(18 passed)cargo test -p xlog-cli --test extraction_cli_tests -- --nocapture(2 passed)Before the conflict-free rebase,
cargo test -p xlog-logicalso completed successfully across the full crate test surface, including 391 library unit tests and all integration binaries.Scope and limits
xlog-clisuite was not used as completion evidence because its long-runningexplain_cli_testsexceeded the 120-second harness limit. The extraction CLI E2E target passed independently.Branch topology
This PR is independent of the Pyxlog/runtime stack in #286-#289 and targets
maindirectly.