proof: package expression helper context head#2100
Merged
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
Bugbot couldn't run - usage limit reachedBugbot is counted against Cursor usage for this user or team, and this run hit a usage or spend limit. A user or team admin can review and increase usage limits in the Cursor dashboard. (requestId: serverGenReqId_5d570dac-5d0f-45ee-9686-8eb9513942a3) |
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.
Summary
ExprInternalHelperCompositionalContextResult, a small expression-context payload that combines outer expression compile/evaluation correspondence with the phase-5 helper-head packageExpr.internalCallhead base theorem that reusesexprInternalHelperCallContextBridge_compileExprWithInternals_internalCalland carries source arg evaluation, compiled Yul arg evaluation to the sameargVals, helper summary/world evidence, helper dispatch, and source/compiled state relationPrintAxioms.leanReferences #2080.
Base / dependency
#2099 is merged, so this PR targets
maindirectly. It is not stacked.Proof status
This is a non-vacuous base-case handoff for the compositional expression-context theorem: the new result shape records the outer expression compile/evaluation facts while preserving the exact phase-5 helper-head evidence. The direct-head theorem constructs that package for
Expr.internalCall.This does not fully close arbitrary non-call expression contexts or
StmtListExprInternalHelperStepInterface. The remaining proof/API blocker is the recursive expression compiler theorem over non-callExprconstructors that constructsExprInternalHelperCompositionalContextResultfor parent contexts and then a statement-head bridge for the expression-bearingStmtcases.Validation
lean-slot lake build Compiler.Proofs.HelperStepProofs(passed; Spark offload denied for this mission path, built locally)lake env lean Compiler/Proofs/HelperStepProofs.lean(passed)python3 scripts/generate_print_axioms.py --check(passed)python3 scripts/check_proof_length.py(passed)rg -n "\\bsorry\\b|\\badmit\\b|\\baxiom\\b" Compiler/Proofs/HelperStepProofs.lean(no matches)make check(passed)Note
Low Risk
Lean proof-only additions with no changes to compilation or runtime semantics; risk is limited to proof maintenance and axiom inventory accuracy.
Overview
Adds
ExprInternalHelperCompositionalContextResult, a proof obligation that ties outer expression compile/source-eval/IR-eval agreement to the existing phase-5 helper-head package (ExprInternalHelperCompiledCallContextResult). The intended follow-on is a recursive theorem over non-callExprconstructors that fills this shape for parent contexts.Proves the direct head base case for
Expr.internalCallviaexprInternalHelperCompositionalContextResult_internalCall_head, reusingexprInternalHelperCallContextBridge_compileExprWithInternals_internalCallplus compile shape, arg evaluation, and value correspondence hypotheses.PrintAxioms.leanis regenerated to register the new public theorem.This does not close arbitrary expression contexts or
StmtListExprInternalHelperStepInterface; it is scaffolding for the compositional expression proof.Reviewed by Cursor Bugbot for commit 0990f8f. Bugbot is set up for automated code reviews on this repo. Configure here.