aboutsummaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorMartin Odersky <odersky@gmail.com>2016-08-24 12:38:22 +0200
committerMartin Odersky <odersky@gmail.com>2016-08-26 11:13:17 +0200
commitb41cff6fa4ccc593916790364424051d9eef200d (patch)
treed2a729c5f885873d725f22f6d4cfe0786836ea59 /tests
parenteb529b556f92a5ab0329899762b43eea7103ad59 (diff)
downloaddotty-b41cff6fa4ccc593916790364424051d9eef200d.tar.gz
dotty-b41cff6fa4ccc593916790364424051d9eef200d.tar.bz2
dotty-b41cff6fa4ccc593916790364424051d9eef200d.zip
Test recategorization
Diffstat (limited to 'tests')
-rw-r--r--tests/neg/t7239.scala (renamed from tests/pending/pos/t7239.scala)10
-rw-r--r--tests/pos-scala2/t7688.scala (renamed from tests/pending/pos/t7688.scala)0
2 files changed, 6 insertions, 4 deletions
diff --git a/tests/pending/pos/t7239.scala b/tests/neg/t7239.scala
index 16e9d00f1..f3a379b4e 100644
--- a/tests/pending/pos/t7239.scala
+++ b/tests/neg/t7239.scala
@@ -1,3 +1,5 @@
+// Dotty rewrites only withFilter calls occurring in for expressions to filter calls.
+// So this test does not compile.
object Test {
def BrokenMethod(): HasFilter[(Int, String)] = ???
@@ -15,12 +17,12 @@ object Test {
(implicit F0: NoImplicit): HasWithFilter = ???
}
- BrokenMethod().withFilter(_ => true) // okay
- BrokenMethod().filter(_ => true) // okay
+ BrokenMethod().withFilter(_ => true) // error
+ BrokenMethod().filter(_ => true) // ok
locally {
import addWithFilter._
- BrokenMethod().withFilter((_: (Int, String)) => true) // okay
+ BrokenMethod().withFilter((_: (Int, String)) => true) // error
}
locally {
@@ -33,6 +35,6 @@ object Test {
// `(B => Boolean)`. Only later during pickling does the
// defensive check for erroneous types in the tree pick up
// the problem.
- BrokenMethod().withFilter(x => true) // erroneous or inaccessible type.
+ BrokenMethod().withFilter(x => true) // error
}
}
diff --git a/tests/pending/pos/t7688.scala b/tests/pos-scala2/t7688.scala
index 5a846b97e..5a846b97e 100644
--- a/tests/pending/pos/t7688.scala
+++ b/tests/pos-scala2/t7688.scala