Skip to content

Conversation

@oskgo
Copy link
Contributor

@oskgo oskgo commented Nov 19, 2025

This fixes #834 and #836.

The fix is to modify the side condition requiring a memory satisfying the left precondition to imply the existence of a right memory satisfying the right precondition and jointly satisfying the two-sided precondition. Now we also require the bounds to be proven equal under these two memories.

In most existing uses this part of the side condition should just simplify away since the bounds should be equal and usually don't depend on memories.

As a side effect this PR also permits uses of this kind of conseq to use bounds that aren't trivially equal, requiring equality to be proven instead.

@oskgo oskgo requested a review from Copilot November 20, 2025 01:14
Copilot finished reviewing on behalf of oskgo November 20, 2025 01:16
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This PR fixes the handling of bounds in the conseq rule for equivalence judgments in phoare logic by adding a side condition that requires bounds to be equal under the appropriate memory substitutions.

Key Changes:

  • Extended transitivity_side_cond to accept optional bound parameters and generate bound equality conditions
  • Modified t_bdHoareF_conseq_equiv to accept and pass the second bound as a parameter
  • Updated the documentation comment to reflect the new bound equality requirement

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@fdupress fdupress requested a review from strub November 21, 2025 14:36
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.

Anomaly when combining pHL and pRHL using conseq in v2025.11

2 participants