summaryrefslogtreecommitdiff
path: root/test/pending
diff options
context:
space:
mode:
authorPaul Phillips <paulp@improving.org>2012-09-28 14:36:42 -0700
committerPaul Phillips <paulp@improving.org>2012-10-09 14:17:34 -0700
commitba36c44c31d1a1e0b5c0cf3d4775edd0ae0d5a13 (patch)
tree8eb8caeb82afa0677a2e78291a990a9e525f3c7e /test/pending
parent432f9368011e0fd9e89ca0e18082bfec180baf32 (diff)
downloadscala-ba36c44c31d1a1e0b5c0cf3d4775edd0ae0d5a13.tar.gz
scala-ba36c44c31d1a1e0b5c0cf3d4775edd0ae0d5a13.tar.bz2
scala-ba36c44c31d1a1e0b5c0cf3d4775edd0ae0d5a13.zip
Fix for SI-4744, another variety of cycle.
I threw this in with the previous commit behind -Ybreak-cycles, but this one is much less sketchy. Explanation: have to handle f-bounds more deftly. Namers forces lower bounds to prevent recursion in that direction, but a light touch is required to handle these two situations differently: // This is a cyclic type parameter - an error is correct class A[T <: Comparable[_ <: T]] // This is not cyclic - it flips the arrow class B[T <: Comparable[_ >: T]] Long have I been haunted by the knowledge that you can write class B in java, but not in scala: public class B<T extends Comparable<? super T>> {} It's over! We've achieved parity with java.
Diffstat (limited to 'test/pending')
-rw-r--r--test/pending/pos/t4744/Bar.scala1
-rw-r--r--test/pending/pos/t4744/Foo.java1
2 files changed, 0 insertions, 2 deletions
diff --git a/test/pending/pos/t4744/Bar.scala b/test/pending/pos/t4744/Bar.scala
deleted file mode 100644
index 1fb6d78973..0000000000
--- a/test/pending/pos/t4744/Bar.scala
+++ /dev/null
@@ -1 +0,0 @@
-class Bar { val quux = new Foo[java.lang.Integer]() }
diff --git a/test/pending/pos/t4744/Foo.java b/test/pending/pos/t4744/Foo.java
deleted file mode 100644
index 6c764d0470..0000000000
--- a/test/pending/pos/t4744/Foo.java
+++ /dev/null
@@ -1 +0,0 @@
-public class Foo<T extends Comparable<? super T>> {}