diff --git a/tools/qfcc/source/qc-parse.y b/tools/qfcc/source/qc-parse.y index 083e453a7..e05958c93 100644 --- a/tools/qfcc/source/qc-parse.y +++ b/tools/qfcc/source/qc-parse.y @@ -452,8 +452,10 @@ var_initializer init_elements ($0, $4); current_init = 0; } - | '=' '#' const + | '=' '#' expr { + if ($3->type == ex_def && $3->e.def->constant) + $3 = constant_expr ($3); build_builtin_function ($0, $3); } | '=' opt_state_expr { $$ = $0; }