-
Notifications
You must be signed in to change notification settings - Fork 262
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
Fix reveal statement inside witness bug #5887
Fix reveal statement inside witness bug #5887
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Two suggestions
Source/IntegrationTests/TestFiles/LitTests/LitTest/ast/reveal/revealInBlock.dfy
Outdated
Show resolved
Hide resolved
@@ -15,15 +14,15 @@ method RevealExpressionScope() | |||
{ | |||
hide *; | |||
var a := (reveal P; assert P(0); true); | |||
assert P(1); // error | |||
assert P(1); // no error, expression leaks. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I hope one day it will be clear enough why it leaks, or it will be the default that it does not leak unless the reveal itself is marked explicitly as leaking.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm still hoping the remove the need for expression statements, but we'll see whether that's possible and desired.
@@ -0,0 +1 @@ | |||
Enable using reveal statement expression inside witness expressions |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Enable using reveal statement expression inside witness expressions | |
Enable using reveal statement expression inside witness expressions when the new resolver is activated with `--type-system-refresh` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I removed this limitation in a previous PR
…revealInBlock.dfy Co-authored-by: Mikaël Mayer <[email protected]>
Fixes #5882
How has this been tested?
CLI test added
By submitting this pull request, I confirm that my contribution is made under the terms of the MIT license.