void (Instruction instruction, int offset, int nextOffset) { if (offset == stopPoint || isWriteToReadVar(instruction)) { // since it's dfs if we even already found some reads, they happened after stop point or after reassignment reachable = false; return; } boolean foundRead = instruction instanceof ReadVariableInstruction && readVars.contains(((ReadVariableInstruction)instruction).variable); reachable |= foundRead; }