From 67635e9dd053bde2fb7d1924a167db8d4278802d Mon Sep 17 00:00:00 2001 From: Bill Currie Date: Tue, 2 Oct 2001 19:03:28 +0000 Subject: [PATCH] fix a d'oh in the param/return type checking --- tools/qfcc/source/expr.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/tools/qfcc/source/expr.c b/tools/qfcc/source/expr.c index 038b4b33e..8bd4a6477 100644 --- a/tools/qfcc/source/expr.c +++ b/tools/qfcc/source/expr.c @@ -1138,6 +1138,7 @@ function_expr (expr_t *e1, expr_t *e2) if (ftype->parm_types[i - 1] == &type_float && e->type == ex_integer) { e->type = ex_float; e->e.float_val = e->e.integer_val; + t = &type_float; } if (ftype->num_parms != -1) { if (t != ftype->parm_types[i - 1]) @@ -1201,6 +1202,7 @@ return_expr (function_t *f, expr_t *e) if (f->def->type->aux_type == &type_float && e->type == ex_integer) { e->type = ex_float; e->e.float_val = e->e.integer_val; + t = &type_float; } if (f->def->type->aux_type != t) return error (e, "type mismatch for return value of %s",