-
Notifications
You must be signed in to change notification settings - Fork 62
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
*&p is not equivalent to p #85
Comments
There is no difference. VeriFast does not allow Note that VeriFast does accept |
I see. I guess my confusion arises actually from the fact that a seemingly side-effect free operation ( /*@ predicate myp(void* p) = true; @*/
void main()
//@ requires true;
//@ ensures myp(_);
{
void* p;
//@ close myp(p);
// @ assert *&p |-> ?x; //<-- uncomment this, and you'll get
// "Cannot perform dereference in this context" on the next line
//@ assert myp(p);
} Here the last assert passes unless I take an address of |
Rather unexpected difference of two terms:
p
and*&p
for a local variablevoid* p;
. For some reason VeriFast does not allow direct use ofp
and prefers*&p |-> ?x; x
instead. Here is the full code:Why is there a difference?
The text was updated successfully, but these errors were encountered: