prevLoop = A->CurLoop;
A->CurLoop = loop;
- cond = _slang_gen_operation(A, &oper->children[0]);
+ cond = new_cond(_slang_gen_operation(A, &oper->children[0]));
breakIf = new_break_if_false(A->CurLoop, cond);
body = _slang_gen_operation(A, &oper->children[1]);
loop->Children[0] = new_seq(breakIf, body);
A->CurLoop = loop;
body = _slang_gen_operation(A, &oper->children[0]);
- cond = _slang_gen_operation(A, &oper->children[1]);
+ cond = new_cond(_slang_gen_operation(A, &oper->children[1]));
breakIf = new_break_if_false(A->CurLoop, cond);
loop->Children[0] = new_seq(body, breakIf);
prevLoop = A->CurLoop;
A->CurLoop = loop;
- cond = _slang_gen_operation(A, &oper->children[1]);
+ cond = new_cond(_slang_gen_operation(A, &oper->children[1]));
breakIf = new_break_if_false(A->CurLoop, cond);
body = _slang_gen_operation(A, &oper->children[3]);
incr = _slang_gen_operation(A, &oper->children[2]);