mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
IDEA-223743 - changed expression comparison method
GitOrigin-RevId: df87941471af933f4582d8525af0b96885ad3ee5
This commit is contained in:
committed by
intellij-monorepo-bot
parent
f10317e766
commit
47b41f6465
@@ -657,7 +657,7 @@ public class ForCanBeForeachInspection extends BaseInspection {
|
||||
private boolean isInsideTryBlock(@NotNull PsiExpression methodExpression) {
|
||||
PsiElement parent = methodExpression.getParent();
|
||||
while (parent != null) {
|
||||
if (parent.isEquivalentTo(context)) return false;
|
||||
if (parent.equals(context)) return false;
|
||||
if (parent instanceof PsiTryStatement) return true;
|
||||
if (parent instanceof PsiFile) return false;
|
||||
parent = parent.getParent();
|
||||
|
||||
Reference in New Issue
Block a user