make void functions actually return float in traditional mode (qcc allowed

things like foo = void_function)
This commit is contained in:
Bill Currie 2003-09-23 16:57:53 +00:00
parent 387464a27c
commit 91207c0180

View file

@ -2122,6 +2122,8 @@ function_expr (expr_t *e1, expr_t *e2)
append_expr (call, e); append_expr (call, e);
if (ftype->aux_type != &type_void) { if (ftype->aux_type != &type_void) {
call->e.block.result = new_ret_expr (ftype->aux_type); call->e.block.result = new_ret_expr (ftype->aux_type);
} else if (options.traditional) {
call->e.block.result = new_ret_expr (&type_float);
} }
return call; return call;
} }