dfa cleanup: skipping reports on method calls is now done via unknown variable mechanism

This commit is contained in:
peter
2013-09-19 18:32:07 +02:00
parent 2765dab243
commit 1cddfb488a
2 changed files with 0 additions and 11 deletions
@@ -349,9 +349,6 @@ public class StandardInstructionVisitor extends InstructionVisitor {
return null;
}
if (isViaMethods(dfaLeft) || isViaMethods(dfaRight)) {
skipConstantConditionReporting(instruction.getPsiAnchor());
}
myCanBeNullInInstanceof.add(instruction);
ArrayList<DfaInstructionState> states = new ArrayList<DfaInstructionState>();
@@ -387,10 +384,6 @@ public class StandardInstructionVisitor extends InstructionVisitor {
ContainerUtil.addIfNotNull(myNotToReportReachability, anchor);
}
private static boolean isViaMethods(DfaValue dfa) {
return dfa instanceof DfaVariableValue && ((DfaVariableValue)dfa).isViaMethods();
}
private void handleInstanceof(InstanceofInstruction instruction, DfaValue dfaRight, DfaValue dfaLeft) {
if (dfaLeft instanceof DfaTypeValue && dfaRight instanceof DfaTypeValue) {
if (!((DfaTypeValue)dfaLeft).isNotNull()) {
@@ -143,10 +143,6 @@ public class DfaVariableValue extends DfaValue {
return myQualifier;
}
public boolean isViaMethods() {
return myVariable instanceof PsiMethod || myQualifier != null && myQualifier.isViaMethods();
}
public Nullness getInherentNullability() {
if (myInherentNullability != null) {
return myInherentNullability;