summaryrefslogtreecommitdiff
path: root/test/files/run/t3888.scala
diff options
context:
space:
mode:
authorPaul Phillips <paulp@improving.org>2010-10-06 22:56:56 +0000
committerPaul Phillips <paulp@improving.org>2010-10-06 22:56:56 +0000
commitcd92aad821eb476f68ea85fb9b149ee185a08e97 (patch)
treed88eb6f15428090f075d7da71ea32e90ceb7cc19 /test/files/run/t3888.scala
parentb8c07db737b55a2ce34190b17013215dc13940ae (diff)
downloadscala-cd92aad821eb476f68ea85fb9b149ee185a08e97.tar.gz
scala-cd92aad821eb476f68ea85fb9b149ee185a08e97.tar.bz2
scala-cd92aad821eb476f68ea85fb9b149ee185a08e97.zip
Unreverting r23174. No review.
Diffstat (limited to 'test/files/run/t3888.scala')
-rw-r--r--test/files/run/t3888.scala26
1 files changed, 26 insertions, 0 deletions
diff --git a/test/files/run/t3888.scala b/test/files/run/t3888.scala
new file mode 100644
index 0000000000..ecdf87e925
--- /dev/null
+++ b/test/files/run/t3888.scala
@@ -0,0 +1,26 @@
+object Test {
+
+ val T1 = new P
+ private[this] val T2 = T1
+
+ def m1 =
+ (1, 2) match {
+ case T1 => true
+ case _ => false
+ }
+
+ def m2 =
+ (1, 2) match {
+ case T2 => true
+ case _ => false
+ }
+
+ def main(args: Array[String]) = {
+ assert( m1 )
+ assert( m2 )
+ }
+}
+
+class P extends Pair(1, 1) {
+ override def equals(x: Any) = true
+} \ No newline at end of file