summaryrefslogtreecommitdiff
path: root/test/files/pos/t7433.scala
Commit message (Collapse)AuthorAgeFilesLines
* SI-7433 Fix spurious warning about catching control throwableJason Zaugg2013-06-231-0/+10
In the same vein as SI-6994, we have to be careful not to warn about synthetic code. In that case, the spurious warnings came because we warned in the typechecker, which was also called in erasure. In this case, we are issuing the warning in Uncurry, so we must be mindful of the pattern matchers translations of non-trivial catch patterns, which look like: case (ex8 @ _) => { <synthetic> val x5: Throwable = ex8; case11(){ if ({ case14(){ if (x5.$isInstanceOf[NullPointerException]()) matchEnd13(true) else case15() }; case15(){ if (x5.$isInstanceOf[RuntimeException]()) matchEnd13(true) else case16() }; case16(){ matchEnd13(false) }; matchEnd13(x: Boolean){ x } }) This commit detects that `ex8` is synthetic and disables the warning.