diff options
author | Martin Odersky <odersky@gmail.com> | 2015-01-18 19:04:05 +0100 |
---|---|---|
committer | Martin Odersky <odersky@gmail.com> | 2015-01-18 19:04:05 +0100 |
commit | 9b260d087a4c63c39e404fd6ba7ade286fdfd8e8 (patch) | |
tree | cf25fbfcc868d7736314a314930b1f58b585996d /tests/pending | |
parent | 14f4c964953535cb7375343ec5e8575e37083aba (diff) | |
download | dotty-9b260d087a4c63c39e404fd6ba7ade286fdfd8e8.tar.gz dotty-9b260d087a4c63c39e404fd6ba7ade286fdfd8e8.tar.bz2 dotty-9b260d087a4c63c39e404fd6ba7ade286fdfd8e8.zip |
Moved previously failing tests to pos
GADTs now work again (they stopped workign when we went to the inductive satisfiability checks).
The deep for expression also works, even with some more levels added.
Diffstat (limited to 'tests/pending')
-rw-r--r-- | tests/pending/pos/i0268.scala | 15 | ||||
-rw-r--r-- | tests/pending/pos/t0674.scala | 49 | ||||
-rw-r--r-- | tests/pending/pos/t1208.scala | 7 | ||||
-rw-r--r-- | tests/pending/pos/t2624.scala | 4 | ||||
-rw-r--r-- | tests/pending/pos/t267.scala | 55 |
5 files changed, 0 insertions, 130 deletions
diff --git a/tests/pending/pos/i0268.scala b/tests/pending/pos/i0268.scala deleted file mode 100644 index 6ac0c5c90..000000000 --- a/tests/pending/pos/i0268.scala +++ /dev/null @@ -1,15 +0,0 @@ -package typespatmat - -sealed trait Box2[T] -final case class Int2(x: Int) extends Box2[Int] -final case class Str2(x: String) - extends Box2[String] -final case class Gen[T](x: T) extends Box2[T] - -object Box2 { - def double2[T](x: Box2[T]): T = x match { - case Int2(i) => i * 2 - case Str2(s) => s + s - case Gen(x) => x - } -} diff --git a/tests/pending/pos/t0674.scala b/tests/pending/pos/t0674.scala deleted file mode 100644 index e405f4b8d..000000000 --- a/tests/pending/pos/t0674.scala +++ /dev/null @@ -1,49 +0,0 @@ -object Test extends App { -println( -for(a <- Some(1); - b <- Some(2); - c <- Some(3); - d <- Some(4); - e <- Some(5); - f <- Some(6); - g <- Some(7); - h <- Some(8); - i <- Some(9); - j <- Some(10); - k <- Some(11); - l <- Some(12) -/* - m <- Some(13); - n <- Some(14); - o <- Some(15); - p <- Some(16); - q <- Some(17); - r <- Some(18); - s <- Some(19); - d <- Some(4); - e <- Some(5); - f <- Some(6); - g <- Some(7); - h <- Some(8); - i <- Some(9); - j <- Some(10); - k <- Some(11); - l <- Some(12); - m <- Some(13); - n <- Some(14); - o <- Some(15); - p <- Some(16); - q <- Some(17); - r <- Some(18); - s <- Some(19); - k <- Some(11); - l <- Some(12); - m <- Some(13); - n <- Some(14); - o <- Some(15)*/ -// p <- Some(16); -// q <- Some(17) -// r <- Some(18); -// s <- Some(19) - ) yield a) -} diff --git a/tests/pending/pos/t1208.scala b/tests/pending/pos/t1208.scala deleted file mode 100644 index 7b14aadca..000000000 --- a/tests/pending/pos/t1208.scala +++ /dev/null @@ -1,7 +0,0 @@ -object Test { - object Foo - val f: Option[Foo.type] = Some(Foo) -} - -// unsupported with current typing rules. -// on the other hand, we need a way to refer to a module class. diff --git a/tests/pending/pos/t2624.scala b/tests/pending/pos/t2624.scala deleted file mode 100644 index 76f0e3036..000000000 --- a/tests/pending/pos/t2624.scala +++ /dev/null @@ -1,4 +0,0 @@ -object Test { - List(1).map(identity(_)) - List(1).map(identity) // this didn't typecheck before the fix -} diff --git a/tests/pending/pos/t267.scala b/tests/pending/pos/t267.scala deleted file mode 100644 index 7e5876eae..000000000 --- a/tests/pending/pos/t267.scala +++ /dev/null @@ -1,55 +0,0 @@ -package expAbstractData - -/** A base class consisting of - * - a root trait (i.e. abstract class) `Exp' with an `eval' function - * - an abstract type `exp' bounded by `Exp' - * - a concrete instance class `Num' of `Exp' for numeric literals - */ -trait Base { - type exp <: Exp - - trait Exp { - def eval: Int - } - class Num(v: Int) extends Exp { self: exp => - val value = v - def eval = value - } -} - -object testBase extends App with Base { - type exp = Exp - val term = new Num(2); - Console.println(term.eval) -} - -/** Data extension: An extension of `Base' with `Plus' expressions - */ -trait BasePlus extends Base { - class Plus(l: exp, r: exp) extends Exp { self: exp => - val left = l - val right = r - def eval = left.eval + right.eval - } -} - -/** Operation extension: An extension of `Base' with 'show' methods. - */ -trait Show extends Base { - type exp <: Exp1 - - trait Exp1 extends Exp { - def show: String - } - class Num1(v: Int) extends Num(v) with Exp1 { self: exp with Num1 => - def show = value.toString() - } -} - -/** Operation extension: An extension of `BasePlus' with 'show' methods. - */ -trait ShowPlus extends BasePlus with Show { - class Plus1(l: exp, r: exp) extends Plus(l, r) with Exp1 { self: exp with Plus1 => - def show = left.show + " + " + right.show - } -} |