You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I was under the impression that permission being negative was not a well-formedness property, but part of the truth value of the contract it is stated in, e.g.:
class C {
int f;
given rational r;
requires Perm(f, r);
void test()
{
}
}
used to verify. This is apparently a change I missed. I guess we nearly never run into this, since we always use frac anyway, which is axiomatically positive (zfrac, non-negative respectively).
NegativePermissionValue should thus not be a ContractFailure, but a VerificationFailure. I have to investigate the implications of this for a bit, but I suspect it won't be a big problem (e.g. scales are already a well-formedness property)
To get to your specific case, funnily enough it appears that it does not verify in VerCors, but does so when passing the output directly to silicon. It appears the order in which functions are verified matters in this case, and it so happens that from vercors readPair is verified before scale, and vice-versa in silicon. We could set --alternativeFunctionVerificationOrder, which would deterministically order readPair/scale, but the documentation says that this may have adverse effects in other cases.
The following input:
Yields:
Removing the
int j
paramter makes the error go away, or removing one of the last tworequires
clauses makes it go away...?The text was updated successfully, but these errors were encountered: