diff options
Diffstat (limited to 'test/files/neg/t1503.scala')
-rw-r--r-- | test/files/neg/t1503.scala | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/test/files/neg/t1503.scala b/test/files/neg/t1503.scala new file mode 100644 index 0000000000..9877f99d0a --- /dev/null +++ b/test/files/neg/t1503.scala @@ -0,0 +1,8 @@ +object Whatever { + override def equals(x: Any) = true +} + +class Test { + // when left to its own devices, and not under -Xfuture, the return type is Whatever.type + def matchWhateverCCE(x: Any) = x match { case n @ Whatever => n } +}
\ No newline at end of file |