/** * Remove the mapping of this variable to a register. * Called when we leave the AST scope of the variable's declaration */ public void unmapRegister(MethodGenerator methodGen) { if (_local != null) { _local.setEnd(methodGen.getInstructionList().getEnd()); methodGen.removeLocalVariable(_local); _refs = null; _local = null; } }
InstructionHandle lastInst = il.getEnd(); il.setPositions();
/** * Translate the "test" expression and contents of this element. * The contents will be ignored if we know the test will always fail. */ public void translate(ClassGenerator classGen, MethodGenerator methodGen) { final InstructionList il = methodGen.getInstructionList(); _test.translateDesynthesized(classGen, methodGen); // remember end of condition final InstructionHandle truec = il.getEnd(); if (!_ignore) { translateContents(classGen, methodGen); } _test.backPatchFalseList(il.append(NOP)); _test.backPatchTrueList(truec.getNext()); } }
lvgEnd = getInstructionList().getEnd();
current.setEnd(body.getEnd());
il.getEnd());
/** * Remove the mapping of this variable to a register. * Called when we leave the AST scope of the variable's declaration */ public void unmapRegister(MethodGenerator methodGen) { if (_local != null) { _local.setEnd(methodGen.getInstructionList().getEnd()); methodGen.removeLocalVariable(_local); _refs = null; _local = null; } }
/** * Remove the mapping of this variable to a register. * Called when we leave the AST scope of the variable's declaration */ public void unmapRegister(MethodGenerator methodGen) { if (_local != null) { _local.setEnd(methodGen.getInstructionList().getEnd()); methodGen.removeLocalVariable(_local); _refs = null; _local = null; } }
/** * Remove the mapping of this variable to a register. * Called when we leave the AST scope of the variable's declaration */ public void unmapRegister(MethodGenerator methodGen) { if (_local != null) { _local.setEnd(methodGen.getInstructionList().getEnd()); methodGen.removeLocalVariable(_local); _refs = null; _local = null; } }
public LocalVariableGen[] getLocalVariables() { final int size = variable_vec.size(); final LocalVariableGen[] lg = new LocalVariableGen[size]; variable_vec.toArray(lg); for (int i = 0; i < size; i++) { if ((lg[i].getStart() == null) && (il != null)) { lg[i].setStart(il.getStart()); } if ((lg[i].getEnd() == null) && (il != null)) { lg[i].setEnd(il.getEnd()); } } if (size > 1) { Arrays.sort(lg, new Comparator<LocalVariableGen>() { @Override public int compare(final LocalVariableGen o1, final LocalVariableGen o2) { return o1.getIndex() - o2.getIndex(); } }); } return lg; }
public LocalVariableGen[] getLocalVariables() { int size = variable_vec.size(); LocalVariableGen[] lg = new LocalVariableGen[size]; variable_vec.toArray(lg); for(int i=0; i < size; i++) { if(lg[i].getStart() == null) lg[i].setStart(il.getStart()); if(lg[i].getEnd() == null) lg[i].setEnd(il.getEnd()); } if(size > 1) sort(lg, 0, size - 1); return lg; }
/** * Translate the "test" expression and contents of this element. * The contents will be ignored if we know the test will always fail. */ public void translate(ClassGenerator classGen, MethodGenerator methodGen) { final InstructionList il = methodGen.getInstructionList(); _test.translateDesynthesized(classGen, methodGen); // remember end of condition final InstructionHandle truec = il.getEnd(); if (!_ignore) { translateContents(classGen, methodGen); } _test.backPatchFalseList(il.append(NOP)); _test.backPatchTrueList(truec.getNext()); } }
/** * Translate the "test" expression and contents of this element. * The contents will be ignored if we know the test will always fail. */ public void translate(ClassGenerator classGen, MethodGenerator methodGen) { final InstructionList il = methodGen.getInstructionList(); _test.translateDesynthesized(classGen, methodGen); // remember end of condition final InstructionHandle truec = il.getEnd(); if (!_ignore) { translateContents(classGen, methodGen); } _test.backPatchFalseList(il.append(NOP)); _test.backPatchTrueList(truec.getNext()); } }
/** * Translate the "test" expression and contents of this element. * The contents will be ignored if we know the test will always fail. */ public void translate(ClassGenerator classGen, MethodGenerator methodGen) { final InstructionList il = methodGen.getInstructionList(); _test.translateDesynthesized(classGen, methodGen); // remember end of condition final InstructionHandle truec = il.getEnd(); if (!_ignore) { translateContents(classGen, methodGen); } _test.backPatchFalseList(il.append(NOP)); _test.backPatchTrueList(truec.getNext()); } }
lvgEnd = getInstructionList().getEnd();
lvgEnd = getInstructionList().getEnd();
lvgEnd = getInstructionList().getEnd();
InstructionHandle ih1_end = il.getEnd(); BranchHandle bh1 = il.append(new GOTO(null));