mirror of
https://git.code.sf.net/p/quake/quakeforge
synced 2025-04-07 01:42:04 +00:00
[qfcc] Handle swizzle expressions when processing
I suspect this is actually a bug in parameter setup for inline function calls, but it would certainly be a bug to get an unprocessed swizzle expression as they're generated from field expressions.
This commit is contained in:
parent
0337a7cd80
commit
a57ea628ca
1 changed files with 13 additions and 0 deletions
|
@ -521,6 +521,18 @@ proc_return (const expr_t *expr, rua_ctx_t *ctx)
|
|||
}
|
||||
}
|
||||
|
||||
static const expr_t *
|
||||
proc_swizzle (const expr_t *expr, rua_ctx_t *ctx)
|
||||
{
|
||||
// To get here, a field expression was processed and then passed to an
|
||||
// inline function.
|
||||
// FIXME this is probably a bug in argument setup for inline functions
|
||||
if (!expr->swizzle.type) {
|
||||
internal_error (expr, "unprocessed swizzle");
|
||||
}
|
||||
return expr;
|
||||
}
|
||||
|
||||
static const expr_t *
|
||||
proc_list (const expr_t *expr, rua_ctx_t *ctx)
|
||||
{
|
||||
|
@ -721,6 +733,7 @@ expr_process (const expr_t *expr, rua_ctx_t *ctx)
|
|||
[ex_assign] = proc_assign,
|
||||
[ex_branch] = proc_branch,
|
||||
[ex_return] = proc_return,
|
||||
[ex_swizzle] = proc_swizzle,
|
||||
[ex_list] = proc_list,
|
||||
[ex_type] = proc_type,
|
||||
[ex_incop] = proc_incop,
|
||||
|
|
Loading…
Reference in a new issue