From: Wolfgang Bumiller Date: Wed, 4 Jul 2012 13:16:02 +0000 (+0200) Subject: Do not actually return after generating a call, there are other isntructions following X-Git-Tag: 0.1-rc1~447 X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=3987509493e204671efa86a01fbad688eaddac43;p=xonotic%2Fgmqcc.git Do not actually return after generating a call, there are other isntructions following --- diff --git a/ast.c b/ast.c index d22e239..e50f168 100644 --- a/ast.c +++ b/ast.c @@ -640,7 +640,9 @@ bool ast_function_codegen(ast_function *self, ir_builder *ir) { if (!self->vtype->expression.next || self->vtype->expression.next->expression.vtype == TYPE_VOID) + { return ir_block_create_return(self->curblock, NULL); + } else { /* error("missing return"); */ diff --git a/ir.c b/ir.c index 41e90d1..e8b7382 100644 --- a/ir.c +++ b/ir.c @@ -2263,7 +2263,7 @@ tailcall: if (code_statements_add(stmt) < 0) return false; } - return true; + continue; } if (instr->opcode == INSTR_STATE) {