Skip to content

feat(opy): complete final #88 source convergence - #156

Merged
Teakowa merged 4 commits into
mainfrom
codex/issue-88-final-convergence
Sep 1, 2026
Merged

feat(opy): complete final #88 source convergence#156
Teakowa merged 4 commits into
mainfrom
codex/issue-88-final-convergence

Conversation

@e54-bot

@e54-bot e54-bot commented Sep 1, 2026

Copy link
Copy Markdown
Contributor

Summary

Verification

  • cargo fmt --all -- --check
  • cargo clippy --workspace --all-targets --all-features -- -D warnings
  • cargo test --workspace --all-targets --all-features — 285 opy-rs unit tests plus all CLI/integration targets passed.
  • python3 -m unittest discover -s compatibility/tests — 28 passed.
  • python3 crates/opy-rs/src/manifest/probes/validate.py — 43/43 pinned probes match.
  • Final full corpus: 63/63 compile-status match; 43 match, 17 documented known-gap, 3 unsupported; semantic-WIR 24 match and 12 accepted-gap; no regression or inconclusive result.

The remaining accepted differences are existing compiler/WIR, preprocessing, or explicitly unsupported control-flow boundaries, all retained with provenance and ownership in the expectation tables; no unowned #141/#144 OPY source capability remains.

Closes #141
Closes #144
Closes #88

Allow expression newlines within delimiter groups while preserving statement boundaries outside groups. Add HIR/span and invalid-form coverage, and refresh corpus expectations after the syntax residuals advance to owner-specific builtin gaps.

Fixes #141
Complete the #141 multiline expression, return, and continue grammar surface with HIR round-trip and canonical loop lowering.

Complete the newly exposed #144 builtin, member, enum, alias, and catalog-backed lowering surface with pinned probes and full-corpus evidence.

Closes #141

Closes #144

Closes #88

@Teakowa Teakowa left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Major — crates/opy-rs/src/lower.rs (context_player_expr)

localPlayer is collapsed to HirExpr::EventPlayer, which the compiler emits as canonical Value::EventPlayer. The pinned Workshop catalog has a distinct localPlayer value, and the pinned Parabola project uses it inside reevaluated expressions where that distinction is observable. Preserve the distinct canonical localPlayer identity through HIR/WIR and add semantic regression coverage for it.

Major — crates/opy-rs/src/compiler/mod.rs (lower_loop_body)

continue lowering only recognizes a top-level continue or an if whose sole branch body is exactly [continue]. Other valid loop-nested shapes fall through lower_action(If) -> lower_actions -> the unsupported Stmt::Continue path, while pinned OverPy resolves continue by walking to the innermost enclosing loop. Make continue lowering work for arbitrary valid loop-nested control flow with nearest-loop semantics, and cover a nested shape beyond the single-action if case.

Major — compatibility/compiler-expectations.json

The newly successful real-world entries remain classification: "known-gap" with semanticEquivalent: false and owner: "opy-rs#88", while this PR closes #88. This violates the file's own evidence policy that known gaps require a concrete follow-up owner and leaves those semantic-WIR differences ownerless after merge. Either demonstrate/classify them as accepted non-semantic or out-of-target differences with the required evidence, or assign an open concrete owner before closing #88.

Preserve localPlayer as its catalog-backed canonical value identity and lower continues through nested loop control flow with nearest-loop semantics.

Move residual compiler expectation ownership off the closing #88 issue to open opy-rs#1 while retaining pinned evidence and explicit gap classifications.

@Teakowa Teakowa left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Major — crates/opy-rs/src/compiler/mod.rs (lower_loop_sequence)

The nested-continue fix still computes a wrong skip distance when the containing if has later elif/else branches. The branch-local distance adds the enclosing End and the outer loop tail, but not the sibling branch headers/bodies that Workshop emission places before that End. A continue in an earlier branch can therefore land before the loop tail instead of at the nearest-loop continuation point. Include the full emitted conditional remainder in the jump distance (or an equivalent nearest-loop target), and cover an if/else or if/elif continue case.

Major — compatibility/compiler-expectations.json

Changing residual owners from closing #88 to #1 does not satisfy the file's concrete follow-up owner contract. #1 is the broad parent engine goal and its planning section routes source-language completion to #88; it is not an executable owner for these individual semantic-WIR/compiler gaps. Assign an open concrete follow-up issue (a coherent category issue is fine), or classify the differences as accepted non-semantic/out-of-target with the required evidence before closing #88.

Include later conditional branches and structural terminators in nearest-loop skip distances, with an if/else regression. Assign the remaining #88 expectation residuals to open opy-rs#157.

@Teakowa Teakowa left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@Teakowa
Teakowa merged commit c8d67f7 into main Sep 1, 2026
5 checks passed
@Teakowa
Teakowa deleted the codex/issue-88-final-convergence branch September 1, 2026 14:47
@e54-bot e54-bot mentioned this pull request Sep 1, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

2 participants