diff options
Diffstat (limited to 'test/files')
-rw-r--r-- | test/files/run/castsingleton.check | 2 | ||||
-rw-r--r-- | test/files/run/castsingleton.scala | 11 |
2 files changed, 13 insertions, 0 deletions
diff --git a/test/files/run/castsingleton.check b/test/files/run/castsingleton.check new file mode 100644 index 0000000000..49742281f0 --- /dev/null +++ b/test/files/run/castsingleton.check @@ -0,0 +1,2 @@ +L() +L() diff --git a/test/files/run/castsingleton.scala b/test/files/run/castsingleton.scala new file mode 100644 index 0000000000..f907467741 --- /dev/null +++ b/test/files/run/castsingleton.scala @@ -0,0 +1,11 @@ +object Test extends Application { + case class L(); + object N extends L(); + + def empty(xs : L) : Unit = xs match { + case x@N => println(x); println(x); + case x => println(x); println(x); + } + + empty(L()) +} |