diff options
Diffstat (limited to 'test/continuations/neg')
-rw-r--r-- | test/continuations/neg/function0.check | 6 | ||||
-rw-r--r-- | test/continuations/neg/function0.scala | 16 | ||||
-rw-r--r-- | test/continuations/neg/function2.check | 6 | ||||
-rw-r--r-- | test/continuations/neg/function2.scala | 16 | ||||
-rw-r--r-- | test/continuations/neg/function3.check | 6 | ||||
-rw-r--r-- | test/continuations/neg/function3.scala | 15 | ||||
-rw-r--r-- | test/continuations/neg/infer0.check | 4 | ||||
-rw-r--r-- | test/continuations/neg/infer0.scala | 14 | ||||
-rw-r--r-- | test/continuations/neg/infer2.check | 4 | ||||
-rw-r--r-- | test/continuations/neg/infer2.scala | 19 | ||||
-rw-r--r-- | test/continuations/neg/lazy.check | 6 | ||||
-rw-r--r-- | test/continuations/neg/lazy.scala | 16 | ||||
-rw-r--r-- | test/continuations/neg/t1929.check | 6 | ||||
-rw-r--r-- | test/continuations/neg/t1929.scala | 17 | ||||
-rw-r--r-- | test/continuations/neg/t2285.check | 6 | ||||
-rw-r--r-- | test/continuations/neg/t2285.scala | 11 | ||||
-rw-r--r-- | test/continuations/neg/t2949.check | 6 | ||||
-rw-r--r-- | test/continuations/neg/t2949.scala | 15 | ||||
-rw-r--r-- | test/continuations/neg/trycatch2.check | 7 | ||||
-rw-r--r-- | test/continuations/neg/trycatch2.scala | 33 |
20 files changed, 0 insertions, 229 deletions
diff --git a/test/continuations/neg/function0.check b/test/continuations/neg/function0.check deleted file mode 100644 index 0a66763a0f..0000000000 --- a/test/continuations/neg/function0.check +++ /dev/null @@ -1,6 +0,0 @@ -function0.scala:11: error: type mismatch; - found : () => Int @scala.util.continuations.cpsParam[Int,Int] - required: () => Int - val g: () => Int = f - ^ -one error found diff --git a/test/continuations/neg/function0.scala b/test/continuations/neg/function0.scala deleted file mode 100644 index 4112ee3835..0000000000 --- a/test/continuations/neg/function0.scala +++ /dev/null @@ -1,16 +0,0 @@ -// $Id$ - -import scala.util.continuations._ - - -object Test { - - def main(args: Array[String]): Any = { - - val f = () => shift { k: (Int=>Int) => k(7) } - val g: () => Int = f - - println(reset(g())) - } - -}
\ No newline at end of file diff --git a/test/continuations/neg/function2.check b/test/continuations/neg/function2.check deleted file mode 100644 index 4833057652..0000000000 --- a/test/continuations/neg/function2.check +++ /dev/null @@ -1,6 +0,0 @@ -function2.scala:11: error: type mismatch; - found : () => Int - required: () => Int @util.continuations.package.cps[Int] - val g: () => Int @cps[Int] = f - ^ -one error found diff --git a/test/continuations/neg/function2.scala b/test/continuations/neg/function2.scala deleted file mode 100644 index ae0fda509d..0000000000 --- a/test/continuations/neg/function2.scala +++ /dev/null @@ -1,16 +0,0 @@ -// $Id$ - -import scala.util.continuations._ - - -object Test { - - def main(args: Array[String]): Any = { - - val f = () => 7 - val g: () => Int @cps[Int] = f - - println(reset(g())) - } - -}
\ No newline at end of file diff --git a/test/continuations/neg/function3.check b/test/continuations/neg/function3.check deleted file mode 100644 index 4705ad9ed9..0000000000 --- a/test/continuations/neg/function3.check +++ /dev/null @@ -1,6 +0,0 @@ -function3.scala:10: error: type mismatch; - found : Int @scala.util.continuations.cpsParam[Int,Int] - required: Int - val g: () => Int = () => shift { k: (Int=>Int) => k(7) } - ^ -one error found diff --git a/test/continuations/neg/function3.scala b/test/continuations/neg/function3.scala deleted file mode 100644 index 0c3f1667e5..0000000000 --- a/test/continuations/neg/function3.scala +++ /dev/null @@ -1,15 +0,0 @@ -// $Id$ - -import scala.util.continuations._ - - -object Test { - - def main(args: Array[String]): Any = { - - val g: () => Int = () => shift { k: (Int=>Int) => k(7) } - - println(reset(g())) - } - -}
\ No newline at end of file diff --git a/test/continuations/neg/infer0.check b/test/continuations/neg/infer0.check deleted file mode 100644 index 1dd072ef09..0000000000 --- a/test/continuations/neg/infer0.check +++ /dev/null @@ -1,4 +0,0 @@ -infer0.scala:11: error: cannot cps-transform expression 8: type arguments [Int(8),String,Int] do not conform to method shiftUnit's type parameter bounds [A,B,C >: B] - test(8) - ^ -one error found diff --git a/test/continuations/neg/infer0.scala b/test/continuations/neg/infer0.scala deleted file mode 100644 index 894d5228b1..0000000000 --- a/test/continuations/neg/infer0.scala +++ /dev/null @@ -1,14 +0,0 @@ -// $Id$ - -import scala.util.continuations._ - - -object Test { - - def test(x: => Int @cpsParam[String,Int]) = 7 - - def main(args: Array[String]): Any = { - test(8) - } - -}
\ No newline at end of file diff --git a/test/continuations/neg/infer2.check b/test/continuations/neg/infer2.check deleted file mode 100644 index 59eb670bc3..0000000000 --- a/test/continuations/neg/infer2.check +++ /dev/null @@ -1,4 +0,0 @@ -infer2.scala:14: error: illegal answer type modification: scala.util.continuations.cpsParam[String,Int] andThen scala.util.continuations.cpsParam[String,Int] - test { sym(); sym() } - ^ -one error found diff --git a/test/continuations/neg/infer2.scala b/test/continuations/neg/infer2.scala deleted file mode 100644 index a890ac1fc4..0000000000 --- a/test/continuations/neg/infer2.scala +++ /dev/null @@ -1,19 +0,0 @@ -// $Id$ - -import scala.util.continuations._ - - -object Test { - - def test(x: => Int @cpsParam[String,Int]) = 7 - - def sym() = shift { k: (Int => String) => 9 } - - - def main(args: Array[String]): Any = { - test { sym(); sym() } - } - -} - - diff --git a/test/continuations/neg/lazy.check b/test/continuations/neg/lazy.check deleted file mode 100644 index bfa44c59a4..0000000000 --- a/test/continuations/neg/lazy.check +++ /dev/null @@ -1,6 +0,0 @@ -lazy.scala:5: error: type mismatch; - found : Unit @scala.util.continuations.cpsParam[Unit,Unit] - required: Unit - def foo = { - ^ -one error found diff --git a/test/continuations/neg/lazy.scala b/test/continuations/neg/lazy.scala deleted file mode 100644 index dffc57ffa0..0000000000 --- a/test/continuations/neg/lazy.scala +++ /dev/null @@ -1,16 +0,0 @@ -import scala.util.continuations._ - -object Test { - - def foo = { - lazy val x = shift((k:Unit=>Unit)=>k()) - println(x) - } - - def main(args: Array[String]) { - reset { - foo - } - } - -}
\ No newline at end of file diff --git a/test/continuations/neg/t1929.check b/test/continuations/neg/t1929.check deleted file mode 100644 index f42c3a1e15..0000000000 --- a/test/continuations/neg/t1929.check +++ /dev/null @@ -1,6 +0,0 @@ -t1929.scala:8: error: type mismatch; - found : Int @scala.util.continuations.cpsParam[String,java.lang.String] @scala.util.continuations.cpsSynth - required: Int @scala.util.continuations.cpsParam[Int,java.lang.String] - reset { - ^ -one error found diff --git a/test/continuations/neg/t1929.scala b/test/continuations/neg/t1929.scala deleted file mode 100644 index 02eda9170d..0000000000 --- a/test/continuations/neg/t1929.scala +++ /dev/null @@ -1,17 +0,0 @@ -// $Id$ - -import scala.util.continuations._ - - -object Test { - def main(args : Array[String]) { - reset { - println("up") - val x = shift((k:Int=>String) => k(8) + k(2)) - println("down " + x) - val y = shift((k:Int=>String) => k(3)) - println("down2 " + y) - y + x - } - } -}
\ No newline at end of file diff --git a/test/continuations/neg/t2285.check b/test/continuations/neg/t2285.check deleted file mode 100644 index d5dff6a4f2..0000000000 --- a/test/continuations/neg/t2285.check +++ /dev/null @@ -1,6 +0,0 @@ -t2285.scala:9: error: type mismatch; - found : Int @scala.util.continuations.cpsParam[String,String] @scala.util.continuations.cpsSynth - required: Int @scala.util.continuations.cpsParam[Int,String] - def foo() = reset { bar(); 7 } - ^ -one error found diff --git a/test/continuations/neg/t2285.scala b/test/continuations/neg/t2285.scala deleted file mode 100644 index f3c7f4c89c..0000000000 --- a/test/continuations/neg/t2285.scala +++ /dev/null @@ -1,11 +0,0 @@ -// $Id$ - -import scala.util.continuations._ - -object Test { - - def bar() = shift { k: (String => String) => k("1") } - - def foo() = reset { bar(); 7 } - -} diff --git a/test/continuations/neg/t2949.check b/test/continuations/neg/t2949.check deleted file mode 100644 index dd9768807c..0000000000 --- a/test/continuations/neg/t2949.check +++ /dev/null @@ -1,6 +0,0 @@ -t2949.scala:13: error: type mismatch; - found : Int - required: ? @scala.util.continuations.cpsParam[List[?],Any] - x * y - ^ -one error found diff --git a/test/continuations/neg/t2949.scala b/test/continuations/neg/t2949.scala deleted file mode 100644 index ce27c7c0e8..0000000000 --- a/test/continuations/neg/t2949.scala +++ /dev/null @@ -1,15 +0,0 @@ -// $Id$ - -import scala.util.continuations._ - -object Test { - - def reflect[A,B](xs : List[A]) = shift{ xs.flatMap[B, List[B]] } - def reify[A, B](x : A @cpsParam[List[A], B]) = reset{ List(x) } - - def main(args: Array[String]): Unit = println(reify { - val x = reflect[Int, Int](List(1,2,3)) - val y = reflect[Int, Int](List(2,4,8)) - x * y - }) -} diff --git a/test/continuations/neg/trycatch2.check b/test/continuations/neg/trycatch2.check deleted file mode 100644 index 5ff2838bad..0000000000 --- a/test/continuations/neg/trycatch2.check +++ /dev/null @@ -1,7 +0,0 @@ -trycatch2.scala:11: error: only simple cps types allowed in try/catch blocks (found: Int @scala.util.continuations.cpsParam[String,Int]) - def foo1 = try { - ^ -trycatch2.scala:19: error: only simple cps types allowed in try/catch blocks (found: Int @scala.util.continuations.cpsParam[String,Int]) - def foo2 = try { - ^ -two errors found diff --git a/test/continuations/neg/trycatch2.scala b/test/continuations/neg/trycatch2.scala deleted file mode 100644 index 761cee52ac..0000000000 --- a/test/continuations/neg/trycatch2.scala +++ /dev/null @@ -1,33 +0,0 @@ -// $Id$ - -import scala.util.continuations._ - -object Test { - - def fatal[T]: T = throw new Exception - def cpsIntStringInt = shift { k:(Int=>String) => k(3); 7 } - def cpsIntIntString = shift { k:(Int=>Int) => k(3); "7" } - - def foo1 = try { - fatal[Int] - cpsIntStringInt - } catch { - case ex => - cpsIntStringInt - } - - def foo2 = try { - fatal[Int] - cpsIntStringInt - } catch { - case ex => - cpsIntStringInt - } - - - def main(args: Array[String]): Unit = { - println(reset { foo1; "3" }) - println(reset { foo2; "3" }) - } - -}
\ No newline at end of file |