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
In short, because lambda equality is assumed to be decidable within Inox' semantics, the assertion in the following testcase is deemed invalid unknown (with --check-models). That stems from Inox assuming that an implementation of bar could discriminate between k and x => k(x), and return a different result in each case. While that is possible in Scala because of reference equality [1], this is in general not something we want to support within Stainlesss' semantics.
We should thus (as discussed with @samarion) add a mode to Inox where lambda equality is deemed undecidable, and enable that mode when used through Stainless. See the corresponding issue in the Inox repository: epfl-lara/inox#87.
We therefore also need to check that user-land code does not rely on such semantics (ie. compare lambdas for equality).
Assuming lambda equality is actually very useful in reasoning about higher-order functions.
We may be encoding parameter passing through equalities or lets and we need to have at least some use of positive equalities in assumptions to get the expected proofs go through.
Background: #62
In short, because lambda equality is assumed to be decidable within Inox' semantics, the assertion in the following testcase is deemed
invalidunknown (with--check-models
). That stems from Inox assuming that an implementation ofbar
could discriminate betweenk
andx => k(x)
, and return a different result in each case. While that is possible in Scala because of reference equality [1], this is in general not something we want to support within Stainlesss' semantics.We should thus (as discussed with @samarion) add a mode to Inox where lambda equality is deemed undecidable, and enable that mode when used through Stainless. See the corresponding issue in the Inox repository: epfl-lara/inox#87.
We therefore also need to check that user-land code does not rely on such semantics (ie. compare lambdas for equality).
[1]
The text was updated successfully, but these errors were encountered: