-
Notifications
You must be signed in to change notification settings - Fork 31
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
CN: Make assert
optional
#922
Comments
Solution may be to parameterise the production for primitive expressions over the return production: https://gallium.inria.fr/~fpottier/menhir/manual.html#sec32 |
There's the basic difference between predicates (return a value) and function specifications (don't). If we want to unify the parsing of predicates and specifications, we could "rename" |
Agreed, I guess we basically want a way to express this without using the "return" keyword and we would then have no conflict: If we want to pick a single name, then perhaps |
A syntax that doesn't require a binder would be ideal. I like |
This is the obvious thing to try, but the issue is that it causes an extra conflict in the parser because this
Simply put, inside a predicate definition, the parser is confused whether
return * x;
is meant to be a return statement, or an implicit assertion.The text was updated successfully, but these errors were encountered: