Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixing old in triggers #710

Merged
merged 4 commits into from
Apr 20, 2023
Merged

Fixing old in triggers #710

merged 4 commits into from
Apr 20, 2023

Conversation

marcoeilers
Copy link
Contributor

@marcoeilers marcoeilers commented Apr 20, 2023

This PR fixes two issues:

In a quantifier with trigger f(e), it could happen that if the quantifier body contained old(f(e)), that Silicon accidentally emitted a trigger essentially equivalent to old(f(e)) instead of the intended trigger (that's the problem behind issue #509). The reason is that when remembering what terms expressions evaluate to, Silicon did not take into acount old, so when evaluating old(f(e)) to some term t during the evaluation of the quantifier body, it would incorrectly remember that f(e) evaluates to t, and thus translate a trigger f(e) accordingly. Now, Silicon correctly remembers that t is the value of old(f(e)).

Second, Silicon used to discard old on the outside of trigger expressions. So if the user supplied a trigger old(e), Silicon would treat this as if they'd just written e. Now it no longer does this.

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.

None yet

1 participant