Skip to content

Restore historical ssreflect rewrite goal ordering - #76

Draft
JasonGross wants to merge 1 commit into
rocq-community:masterfrom
theorem-labs:claude/rocq-dev-compat
Draft

Restore historical ssreflect rewrite goal ordering#76
JasonGross wants to merge 1 commit into
rocq-community:masterfrom
theorem-labs:claude/rocq-dev-compat

Conversation

@JasonGross

Copy link
Copy Markdown
Member

MathComp dev no longer globally enables SsrOldRewriteGoalsOrder, but several proofs in this development rely on the former conditional-rewrite goal ordering. Enable the option explicitly and globally in prelude.v, which is imported throughout the library.

Validation: a clean make -j8 build completes successfully against Rocq dev and MathComp dev in the rocq-dev-testing opam switch. The build emits deprecation warnings but no errors.

The compatibility change was developed by a Claude coding-agent session and independently reviewed and validated by OpenAI Codex.

Authorship note: this was researched and written by an AI coding agent
(OpenAI Codex), working on Jason Gross's behalf; Jason reviews what is
posted from this account.

Several proofs in this development use conditional ssreflect rewrites
together with `last by` / `first by` / `last first`, which relies on the
side conditions being produced after the main goal.  MathComp <= 2.5.0
enabled `SsrOldRewriteGoalsOrder` globally in mathcomp/boot/ssreflect.v,
so the option was on for us; MathComp dev no longer does, and the Rocq
option reverts to its default (off), which reorders those goals and
breaks the proofs in finmap.v, heaps.v, stmod.v and terms.v.

Set the option explicitly in prelude.v, which every other file requires.
The option exists in Rocq 9.0 through dev, so this stays backwards
compatible; verified building with Rocq 9.0, 9.1, 9.2 and 9.4+alpha.

Co-Authored-By: Claude Opus 5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01L9BGQT7XUuubV6C619DW4b
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant