diff options
Diffstat (limited to 'test/files/neg')
-rw-r--r-- | test/files/neg/unchecked.check | 2 | ||||
-rw-r--r-- | test/files/neg/unchecked.scala | 11 |
2 files changed, 13 insertions, 0 deletions
diff --git a/test/files/neg/unchecked.check b/test/files/neg/unchecked.check new file mode 100644 index 0000000000..0747cddefb --- /dev/null +++ b/test/files/neg/unchecked.check @@ -0,0 +1,2 @@ +warning: there were unchecked warnings; re-run with -unchecked for details +one warning found diff --git a/test/files/neg/unchecked.scala b/test/files/neg/unchecked.scala new file mode 100644 index 0000000000..6cae0642bc --- /dev/null +++ b/test/files/neg/unchecked.scala @@ -0,0 +1,11 @@ +abstract class Test { + type T <: Option[String] + val x: Option[String] + def f { + x match { + case x: T => Console.println("4") + case a: Some[String] => Console.println("3") + case None => Console.println("else case") + } + } +} |