Skip to content
Snippets Groups Projects
Commit a8a18953 authored by Viktor Kuncak's avatar Viktor Kuncak
Browse files

one can use lemmas by conjoining their instances

parent 48adb815
No related branches found
No related tags found
No related merge requests found
......@@ -51,4 +51,9 @@ object RedBlackTree {
case Node(Red(),l,v,r) => Node(Black(),l,v,r)
case _ => n
}
def flip(t : Tree) : Tree = t match {
case Empty() => Empty()
case Node(color,l,e,r) => Node(color,flip(r),e,flip(l))
}
}
import scala.collection.immutable.Set
import funcheck.Utils._
import funcheck.Annotations._
object UseContradictoryLemma {
def lemma1(x : Int) : Boolean = {
x == 1
} holds
def f(x : Int) : Int = {
5
} ensuring (x => lemma1(x) && x == 1)
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment