diff options
Diffstat (limited to 'test')
-rw-r--r-- | test/files/pos/unapplyVal.scala | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/test/files/pos/unapplyVal.scala b/test/files/pos/unapplyVal.scala new file mode 100644 index 0000000000..3816152f20 --- /dev/null +++ b/test/files/pos/unapplyVal.scala @@ -0,0 +1,18 @@ +package test // bug #1215 + +class Async { + def unapply(scrut: Any): Option[Any] = None +} + +class Buffer { + val Put = new Async + //case class Put(x: int) + + def joinPat(x: Any): Unit = { + x match { + case Put => + case Put(y) => + println("returning "+y) + } + } +} |