MIRROR: javascript for ๐Ÿœ's, a tiny runtime with big ambitions
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

fix condition handling when consumed token flag is set in if statement

+1 -1
+1 -1
src/ant.c
··· 11797 11797 if (cond_true) res = blk; 11798 11798 if (exe && !cond_true) js->flags &= (uint8_t) ~F_NOEXEC; 11799 11799 11800 - if (next(js) == TOK_ELSE || lookahead(js) == TOK_ELSE) { 11800 + if ((!js->consumed && js->tok == TOK_ELSE) || lookahead(js) == TOK_ELSE) { 11801 11801 if (js->tok != TOK_ELSE) { js->consumed = 1; next(js); } 11802 11802 js->consumed = 1; 11803 11803 if (cond_true) js->flags |= F_NOEXEC;