void (@NotNull UnsatisfiedConditionProblem problem, @NotNull DfaValue value, @NotNull ThreeState failed, @NotNull DfaMemoryState state) { if (problem instanceof ArrayStoreProblem) { addHint(((ArrayStoreProblem)problem).getAnchor().getLExpression(), failed == ThreeState.YES ? DfaHint.ASE : DfaHint.NONE); } else if (problem instanceof ArrayIndexProblem) { PsiArrayAccessExpression anchor = ((ArrayIndexProblem)problem).getAnchor(); // Anchor to the last child to differentiate from ArrayStoreException addHint(anchor.getLastChild(), failed == ThreeState.YES ? DfaHint.AIOOBE : DfaHint.NONE); } else if (problem instanceof ClassCastProblem) { addHint(((ClassCastProblem)problem).getAnchor(), failed == ThreeState.YES ? DfaHint.CCE : DfaHint.NONE); } else if (problem instanceof NullabilityProblemKind.NullabilityProblem<?> npeProblem) { PsiExpression expression = npeProblem.getDereferencedExpression(); if (expression != null && npeProblem.thrownException() != null) { DfaHint hint; if (failed == ThreeState.YES) { hint = npeProblem.thrownException().equals(CommonClassNames.JAVA_LANG_NULL_POINTER_EXCEPTION) ? DfaHint.NPE : DfaHint.NULL_AS_NOT_NULL; } else { hint = DfaHint.NONE; } addHint(expression, hint); } } }