From c629de9b3b86d0feb40fdaf1a7b6676a858257fd Mon Sep 17 00:00:00 2001 From: Bill Currie Date: Tue, 26 Jun 2001 23:42:11 +0000 Subject: [PATCH] function calls work now --- tools/qfcc/source/expr.c | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/tools/qfcc/source/expr.c b/tools/qfcc/source/expr.c index 17cbe9515..29bac865b 100644 --- a/tools/qfcc/source/expr.c +++ b/tools/qfcc/source/expr.c @@ -695,10 +695,16 @@ emit_function_call (expr_t *e, def_t *dest) emit_statement (op, arg, &def_parms[ind], 0); } op = PR_Opcode_Find (va ("", count), -1, &def_function, &def_void, &def_void); - emit_statement (op, func, 0, dest); + emit_statement (op, func, 0, 0); def_ret.type = func->type->aux_type; - return &def_ret; + if (dest) { + op = PR_Opcode_Find ("=", 5, dest, &def_ret, &def_ret); + emit_statement (op, &def_ret, dest, 0); + return dest; + } else { + return &def_ret; + } } def_t *