summaryrefslogtreecommitdiff
path: root/test/files/pos/t5589.scala
diff options
context:
space:
mode:
authorPaul Phillips <paulp@improving.org>2012-03-20 13:05:17 -0700
committerPaul Phillips <paulp@improving.org>2012-03-20 13:55:15 -0700
commitd8ba5d091e5641553b438ef9930a6023a2709dcd (patch)
tree6d1f0dce613bea08926005b0232033c774a68970 /test/files/pos/t5589.scala
parent743d954abfae4ae8a2e2886dc527df6a33a669c1 (diff)
downloadscala-d8ba5d091e5641553b438ef9930a6023a2709dcd.tar.gz
scala-d8ba5d091e5641553b438ef9930a6023a2709dcd.tar.bz2
scala-d8ba5d091e5641553b438ef9930a6023a2709dcd.zip
Revert irrefutability commits.
Temporary reversion of irrefutability commits in interests of stable milestone. Expect to restore shortly.
Diffstat (limited to 'test/files/pos/t5589.scala')
-rw-r--r--test/files/pos/t5589.scala22
1 files changed, 0 insertions, 22 deletions
diff --git a/test/files/pos/t5589.scala b/test/files/pos/t5589.scala
deleted file mode 100644
index 69cbb20391..0000000000
--- a/test/files/pos/t5589.scala
+++ /dev/null
@@ -1,22 +0,0 @@
-class A {
- // First three compile.
- def f1(x: Either[Int, String]) = x.right map (y => y)
- def f2(x: Either[Int, String]) = for (y <- x.right) yield y
- def f3(x: Either[Int, (String, Int)]) = x.right map { case (y1, y2) => (y1, y2) }
- // Last one fails.
- def f4(x: Either[Int, (String, Int)]) = for ((y1, y2) <- x.right) yield ((y1, y2))
-/**
-./a.scala:5: error: constructor cannot be instantiated to expected type;
- found : (T1, T2)
- required: Either[Nothing,(String, Int)]
- def f4(x: Either[Int, (String, Int)]) = for ((y1, y2) <- x.right) yield ((y1, y2))
- ^
-./a.scala:5: error: not found: value y1
- def f4(x: Either[Int, (String, Int)]) = for ((y1, y2) <- x.right) yield ((y1, y2))
- ^
-./a.scala:5: error: not found: value y2
- def f4(x: Either[Int, (String, Int)]) = for ((y1, y2) <- x.right) yield ((y1, y2))
- ^
-three errors found
-**/
-}