mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
DfaMemoryStateImpl: Avoid SOE when canonicalizing rewritten temp variable
Fixes EA-136794 - NA: DfaMemoryStateImpl.replaceQualifier
This commit is contained in:
+19
@@ -0,0 +1,19 @@
|
||||
import java.util.*;
|
||||
import java.util.function.*;
|
||||
|
||||
class X {
|
||||
Optional<Optional<?>> opt1;
|
||||
void test(int i) {
|
||||
Optional<?> res = ((Supplier<Optional<?>>)() -> {
|
||||
try {
|
||||
if (opt1.get() == opt1) {
|
||||
return opt1;
|
||||
}
|
||||
}
|
||||
finally {
|
||||
return Optional.empty();
|
||||
}
|
||||
}).get();
|
||||
if(<warning descr="Condition 'res.isPresent()' is always 'false'">res.isPresent()</warning>) {}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user