fixed bugs in loop handling for infeasible code detection.