diff options
Diffstat (limited to 'test/files/run/ctries-new')
-rw-r--r-- | test/files/run/ctries-new/main.scala | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/test/files/run/ctries-new/main.scala b/test/files/run/ctries-new/main.scala index d7fe087e4d..34f3ec2ccf 100644 --- a/test/files/run/ctries-new/main.scala +++ b/test/files/run/ctries-new/main.scala @@ -21,6 +21,9 @@ object Test { trait Spec { + implicit def implicitously = scala.language.implicitConversions + implicit def reflectively = scala.language.reflectiveCalls + implicit def str2ops(s: String) = new { def in[U](body: =>U) { // just execute body @@ -37,11 +40,11 @@ trait Spec { var produced = false try body catch { - case e => if (e.getClass == implicitly[ClassTag[T]].runtimeClass) produced = true + case e: Throwable => if (e.getClass == implicitly[ClassTag[T]].runtimeClass) produced = true } finally { assert(produced, "Did not produce exception of type: " + implicitly[ClassTag[T]]) } } } -}
\ No newline at end of file +} |