contract inference: don't go inside try because catch/finally clauses can change the outcome completely

This commit is contained in:
peter
2014-09-01 10:43:30 +02:00
parent fdd3376d7a
commit 5ac0709ec3
2 changed files with 0 additions and 19 deletions
@@ -334,19 +334,6 @@ class ContractInferenceFromSourceTest extends LightCodeInsightFixtureTestCase {
assert c == ['null -> null']
}
public void "test go inside try"() {
def c = inferContracts("""
final Object foo(Object bar) {
try {
if (bar == null) return null;
bar = smth(bar);
} finally {}
return new String("abc");
}
""")
assert c == ['null -> null']
}
public void "test use invoked method notnull"() {
def c = inferContracts("""
final Object foo(Object bar) {