diff options
Diffstat (limited to 'test/files/pos/exceptions.scala')
-rw-r--r-- | test/files/pos/exceptions.scala | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/test/files/pos/exceptions.scala b/test/files/pos/exceptions.scala index c47b0e4785..f28a10d367 100644 --- a/test/files/pos/exceptions.scala +++ b/test/files/pos/exceptions.scala @@ -4,7 +4,7 @@ object test { //def error[a](x: String):a = new java.lang.RuntimeException(x) throw; - def main(): Unit = { + def main(args: Array[String]): Unit = { try { try { System.out.println("hi!"); @@ -12,11 +12,10 @@ object test { } finally { System.out.println("ho!") } - } except { + } catch { case ex: IOException => System.out.println("io exception!"); case ex => System.out.println(ex); } } - main(); } |