Skip to content

Conversation

wadoon
Copy link
Member

@wadoon wadoon commented Sep 2, 2025

Intended Change

This PR generalizes the usage of proof script blocks further.

Currently, you are allowed to have one proof script block at the end of a command:

onAll { auto;}

With this PR, proof script blocks can appear as a regular argument anywhere (positional and keyworded):

integer-split 
  "<0" : { auto;  }
  "=0" : { instantiate; } 
  ">0" : { tryclose; }

This allows for various constructs, e.g.,

if "cond" { .. then ..} {.. else ..}

Plan

  • Do it
  • Test it

Type of pull request

  • New feature (non-breaking change which adds functionality)
  • There are changes to the (Java) code

Ensuring quality

  • I made sure that introduced/changed code is well documented (javadoc and inline comments).

@wadoon wadoon added this to the v2.12.4 milestone Sep 2, 2025
@wadoon wadoon requested a review from mattulbrich September 2, 2025 12:17
@wadoon wadoon self-assigned this Sep 2, 2025
@wadoon wadoon changed the title Weigl/psg higherfunction Higher Order Proof Scripts Sep 2, 2025
@wadoon wadoon force-pushed the weigl/psg-higherfunction branch 2 times, most recently from ea5349e to a06eb4d Compare September 7, 2025 02:56
@wadoon wadoon marked this pull request as ready for review September 7, 2025 02:56
@wadoon
Copy link
Member Author

wadoon commented Sep 7, 2025

The semicolon is not mandatory again.

@wadoon wadoon force-pushed the weigl/psg-higherfunction branch from 8bb0c34 to b1e6df1 Compare September 7, 2025 14:19
@wadoon wadoon force-pushed the weigl/psg-higherfunction branch from b1e6df1 to 448bca4 Compare September 7, 2025 14:20
Copy link
Member

@mattulbrich mattulbrich left a comment

Choose a reason for hiding this comment

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

Nice. It looks actually cleaner with this generalisation.

Not thoroughly tested since the upcoming JML scripts will put this to the test.

@wadoon wadoon enabled auto-merge September 8, 2025 15:50
@wadoon wadoon added this pull request to the merge queue Sep 8, 2025
Merged via the queue into main with commit 5aa36a1 Sep 8, 2025
35 checks passed
@wadoon wadoon deleted the weigl/psg-higherfunction branch September 8, 2025 18:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants