IDEA-114169 (false positive for non-intersecting throwers)

This commit is contained in:
Roman Shevchenko
2013-09-30 14:51:38 +02:00
parent 335436ebd7
commit 39e5e2087f
3 changed files with 36 additions and 10 deletions

View File

@@ -0,0 +1,18 @@
import java.io.*;
class Test {
abstract class Target {
abstract void call(String f) throws FileNotFoundException, IOException;
abstract void call(String[] f) throws FileNotFoundException, IOException;
}
void use(Target target) throws IOException {
try {
target.call("");
} catch (FileNotFoundException e) {
System.out.println("file not found");
} catch (IOException e) {
System.out.println("failed: " + e);
}
}
}