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
edit: of course Stainless needs @mutable parameter on A in app; I had inadvertedly removed it as I was testing it in REPL. The use in REPL confirms that the program crashes at run time due to assertion viaolation, yet it verifies with stainless Version: 0.9.7-7-g99a3f92
The text was updated successfully, but these errors were encountered:
In my view, we should just disable capturing of mutable objects inside closures.
If you need to capture something, you need to do it through objects of some other class, and then aliasing checks need to apply.
We should also check what happens if we do similar construction using inner classes.
While one can imagine generalization to allow this, I believe that we should for now use the basic type systems to enforce that functions are only working on their arguments and do not capture anything mutable. For more general case, I propose to use a different type, see #1369
Stainless freezes the value of a closure incorrectly at creation time, resulting in unsoundness.
For example, it verifies this.
edit: of course Stainless needs
@mutable
parameter onA
inapp
; I had inadvertedly removed it as I was testing it in REPL. The use in REPL confirms that the program crashes at run time due to assertion viaolation, yet it verifies with stainless Version: 0.9.7-7-g99a3f92The text was updated successfully, but these errors were encountered: