vkd3d-shader/hlsl: Return an hlsl_ir_node pointer from hlsl_new_int_constant().

This commit is contained in:
Zebediah Figura
2022-11-10 20:06:59 -06:00
committed by Alexandre Julliard
parent a4a95aa950
commit dfe056596a
Notes: Alexandre Julliard 2023-04-20 22:58:03 +02:00
Approved-by: Giovanni Mascellani (@giomasce)
Approved-by: Henri Verbeet (@hverbeet)
Approved-by: Alexandre Julliard (@julliard)
Merge-Request: https://gitlab.winehq.org/wine/vkd3d/-/merge_requests/169
3 changed files with 8 additions and 10 deletions

View File

@@ -1149,8 +1149,7 @@ struct hlsl_ir_node *hlsl_new_float_constant(struct hlsl_ctx *ctx, float f,
return &c->node;
}
struct hlsl_ir_constant *hlsl_new_int_constant(struct hlsl_ctx *ctx, int n,
const struct vkd3d_shader_location *loc)
struct hlsl_ir_node *hlsl_new_int_constant(struct hlsl_ctx *ctx, int32_t n, const struct vkd3d_shader_location *loc)
{
struct hlsl_ir_constant *c;
@@ -1159,7 +1158,7 @@ struct hlsl_ir_constant *hlsl_new_int_constant(struct hlsl_ctx *ctx, int n,
if (c)
c->value[0].i = n;
return c;
return &c->node;
}
struct hlsl_ir_constant *hlsl_new_uint_constant(struct hlsl_ctx *ctx, unsigned int n,