public static PsiExpression @NotNull [] findExpressionOccurrences(PsiElement scope, PsiExpression expr) {
    List<PsiExpression> array = new ArrayList<>();
    TrackingEquivalenceChecker equivalenceChecker = new TrackingEquivalenceChecker();
    addExpressionOccurrences(CommonJavaRefactoringUtil.unparenthesizeExpression(expr), array, scope, equivalenceChecker);
    if (expr.isPhysical()) {
      boolean found = false;
      for (PsiExpression psiExpression : array) {
        if (PsiTreeUtil.isAncestor(expr, psiExpression, false) || PsiTreeUtil.isAncestor(psiExpression, expr, false)) {
          found = true;
          break;
        }
      }
      if (!found) array.add(expr);
    }
    return array.toArray(PsiExpression.EMPTY_ARRAY);
  }
public static PsiExpression @NotNull [] findExpressionOccurrences(PsiElement scope, PsiExpression expr)