mirror of
https://gitlab.winehq.org/wine/vkd3d.git
synced 2025-01-28 13:05:02 -08:00
vkd3d-shader/hlsl: Move the base type equality case in expr_common_base_type.
Signed-off-by: Giovanni Mascellani <gmascellani@codeweavers.com> Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com> Signed-off-by: Zebediah Figura <zfigura@codeweavers.com> Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
parent
54bef05070
commit
5a55e8e8d5
@ -916,6 +916,9 @@ static enum hlsl_base_type expr_common_base_type(enum hlsl_base_type t1, enum hl
|
||||
};
|
||||
int t1_idx = -1, t2_idx = -1, i;
|
||||
|
||||
if (t1 == t2)
|
||||
return t1;
|
||||
|
||||
for (i = 0; i < ARRAY_SIZE(types); ++i)
|
||||
{
|
||||
/* Always convert away from HLSL_TYPE_HALF */
|
||||
@ -981,10 +984,7 @@ static struct hlsl_type *expr_common_type(struct hlsl_ctx *ctx, struct hlsl_type
|
||||
return NULL;
|
||||
}
|
||||
|
||||
if (t1->base_type == t2->base_type)
|
||||
base = t1->base_type;
|
||||
else
|
||||
base = expr_common_base_type(t1->base_type, t2->base_type);
|
||||
base = expr_common_base_type(t1->base_type, t2->base_type);
|
||||
|
||||
if (t1->dimx == 1 && t1->dimy == 1)
|
||||
{
|
||||
|
Loading…
x
Reference in New Issue
Block a user