If I am getting an error on a function that a variable opcode may not have been initialized, should this be done inside this method or in the beginning of the class.
private void compileDo() {
int endLabel, endLabelLoc, topLabel, opcode;
accept("do");
accept("(");
compileExpr();
accept(")");
topLabel = cs.getPos();
endLabelLoc = cs.emit(opcode, topLabel);
compileStatement();
}
Any help would be most appreciated.