From 17314a1fb316eb712ae0c539ccea64fe1aeb5c93 Mon Sep 17 00:00:00 2001 From: Thomas Preud'homme Date: Tue, 4 Feb 2014 20:54:28 +0800 Subject: Fix parameter passing of long long bitfield --- tccgen.c | 3 +++ 1 file changed, 3 insertions(+) (limited to 'tccgen.c') diff --git a/tccgen.c b/tccgen.c index c5e368e..03a446a 100644 --- a/tccgen.c +++ b/tccgen.c @@ -3490,6 +3490,9 @@ static void gfunc_param_typed(Sym *func, Sym *arg) if ((vtop->type.t & VT_BTYPE) == VT_FLOAT) { type.t = VT_DOUBLE; gen_cast(&type); + } else if (vtop->type.t & VT_BITFIELD) { + type.t = vtop->type.t & (VT_BTYPE | VT_UNSIGNED); + gen_cast(&type); } } else if (arg == NULL) { tcc_error("too many arguments to function"); -- cgit v1.3.1