diff options
author | Dmitry Petrashko <dmitry.petrashko@gmail.com> | 2014-10-27 14:59:07 +0100 |
---|---|---|
committer | Dmitry Petrashko <dmitry.petrashko@gmail.com> | 2014-10-30 17:21:04 +0100 |
commit | e44e4aa7e818d7eb90316880cd0758c65298f2a8 (patch) | |
tree | 5956a1d7047060b45bedeb311ac3e04bf989a9d3 /tests/pos | |
parent | 1be3b2fd50487b20812b57ef485e8983dea7c289 (diff) | |
download | dotty-e44e4aa7e818d7eb90316880cd0758c65298f2a8.tar.gz dotty-e44e4aa7e818d7eb90316880cd0758c65298f2a8.tar.bz2 dotty-e44e4aa7e818d7eb90316880cd0758c65298f2a8.zip |
TailRec now handles Try with Ident-handler
Diffstat (limited to 'tests/pos')
-rw-r--r-- | tests/pos/tryTyping.scala | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/tests/pos/tryTyping.scala b/tests/pos/tryTyping.scala new file mode 100644 index 000000000..35180bee9 --- /dev/null +++ b/tests/pos/tryTyping.scala @@ -0,0 +1,14 @@ +object tryTyping{ + def foo: Int = { + try{???; 1} + catch { + case e: Exception => 2 + } + } + + def foo2: Int = { + val a: (Throwable => Int) = _ match {case _ => 2} + try{???; 1} + catch a + } +}
\ No newline at end of file |