コード例 #1
0
 private void flushForeachLoopVariable(@Nullable GrForClause clause) {
   if (clause instanceof GrForInClause) {
     GrVariable variable = clause.getDeclaredVariable();
     if (variable != null && myPolicy.isVariableInitialized(variable)) {
       addNodeAndCheckPending(
           new ReadWriteVariableInstruction(variable.getName(), variable, WRITE));
     }
   }
 }
コード例 #2
0
  public void visitVariable(GrVariable variable) {
    super.visitVariable(variable);

    if (myPolicy.isVariableInitialized(variable)) {
      ReadWriteVariableInstruction writeInst =
          new ReadWriteVariableInstruction(variable.getName(), variable, WRITE);
      addNodeAndCheckPending(writeInst);
    }
  }