IDEA-84036 Redundant thrown exception not detected if the method calls itself

This commit is contained in:
Maxim Shafirov
2012-04-03 22:09:45 +04:00
parent cd874dba27
commit accc2bf284
5 changed files with 48 additions and 7 deletions
@@ -0,0 +1,9 @@
<?xml version="1.0" encoding="UTF-8"?>
<problems>
<problem>
<file>Foo.java</file>
<line>4</line>
<description>IOException</description>
</problem>
</problems>
@@ -0,0 +1,9 @@
import java.io.*;
public class Foo {
public void foo() throws IOException {
if (4 > 3) {
foo();
}
}
}
@@ -41,4 +41,9 @@ public class RedundantThrowTest extends InspectionTestCase {
public void testimplicitSuper() throws Exception {
doTest();
}
public void testselfCall() throws Exception {
doTest();
}
}