There seems of no use to add a goto at the end of CAstStatAssign::ToTac()
The redundant line is marked in the code block.
In control flows, there will be a goto in the intermediate code, which is actually a infinite loop. Please refer to test/tac/test3.mod to check the result.
CTacAddr* CAstStatAssign::ToTac(CCodeBlock *cb, CTacLabel *next)
{
// CTacAddr *dst = GetLHS()->ToTac(cb);
CTacAddr *src = GetRHS()->ToTac(cb); // gets the TAC of RHS
CTacAddr *dst = GetLHS()->ToTac(cb); // gets the TAC of LHS
cb->AddInstr(new CTacInstr(opAssign, dst, src));
cb->AddInstr(new CTacInstr(opGoto, next)); // this line is redundant
return NULL;
}