d3dcompiler: Use the cached scalar type in expr_common_type() where possible.

Signed-off-by: Zebediah Figura <zfigura@codeweavers.com>
Signed-off-by: Matteo Bruni <mbruni@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
Zebediah Figura 2020-06-08 16:49:34 -05:00 committed by Alexandre Julliard
parent 8d12efecc9
commit 9c985e703b
1 changed files with 2 additions and 0 deletions

View File

@ -1294,6 +1294,8 @@ static struct hlsl_type *expr_common_type(struct hlsl_type *t1, struct hlsl_type
}
}
if (type == HLSL_CLASS_SCALAR)
return hlsl_ctx.builtin_types.scalar[base];
return new_hlsl_type(NULL, type, base, dimx, dimy);
}