summaryrefslogtreecommitdiff
path: root/test/files/run/virtpatmat_extends_product.scala
diff options
context:
space:
mode:
authorPaul Phillips <paulp@improving.org>2012-10-16 08:07:17 -0700
committerPaul Phillips <paulp@improving.org>2012-10-22 14:13:53 -0700
commitd7f498ac9cccd7473be8f416a1620548ca8fca9b (patch)
treee9afec34e249414b5ffa67b06de49df6401db5e8 /test/files/run/virtpatmat_extends_product.scala
parent6daf9c642578c0af178075f5cc10e2a19c35e12a (diff)
downloadscala-d7f498ac9cccd7473be8f416a1620548ca8fca9b.tar.gz
scala-d7f498ac9cccd7473be8f416a1620548ca8fca9b.tar.bz2
scala-d7f498ac9cccd7473be8f416a1620548ca8fca9b.zip
Disabled generation of _1, _2, etc. methods.
This was part of the introduction of ProductN, which had to go back into pandora's box because of issues with cycles during typing. These should have been reverted along with it.
Diffstat (limited to 'test/files/run/virtpatmat_extends_product.scala')
-rw-r--r--test/files/run/virtpatmat_extends_product.scala7
1 files changed, 5 insertions, 2 deletions
diff --git a/test/files/run/virtpatmat_extends_product.scala b/test/files/run/virtpatmat_extends_product.scala
index e564f4430b..4b4bc634a7 100644
--- a/test/files/run/virtpatmat_extends_product.scala
+++ b/test/files/run/virtpatmat_extends_product.scala
@@ -1,5 +1,8 @@
object Test extends App {
- case class AnnotationInfo(a: String, b: Int) extends Product2[String, Int]
+ case class AnnotationInfo(a: String, b: Int) extends Product2[String, Int] {
+ def _1 = a
+ def _2 = b
+ }
// if we're not careful in unapplyTypeListFromReturnType, the generated unapply is
// thought to return two components instead of one, since AnnotationInfo (the result of the unapply) is a Product2
@@ -8,4 +11,4 @@ object Test extends App {
NestedAnnotArg(AnnotationInfo("a", 1)) match {
case NestedAnnotArg(x) => println(x)
}
-} \ No newline at end of file
+}