Re: [PATCH v3 0/5] MR781: Avoid HLSL_CLASS_OBJECT, part 4.
Giovanni Mascellani (@giomasce) commented about libs/vkd3d-shader/hlsl.c:
return type->reg_size[regset]; }
+static struct hlsl_type *hlsl_new_simple_type(struct hlsl_ctx *ctx, const char *name, enum hlsl_type_class class) +{ + struct hlsl_type *type; + + if (!(type = hlsl_alloc(ctx, sizeof(*type)))) + return NULL; + if (!(type->name = hlsl_strdup(ctx, name))) + { + vkd3d_free(type); + return NULL; + } + type->class = class;
This doesn't set `dimx` and `dimy`, while in the documentation for `struct hlsl_type` we specify them for all classes. Either relaxing the specification or setting them here is fine for me, but at least one of those should happen, I think. -- https://gitlab.winehq.org/wine/vkd3d/-/merge_requests/781#note_67910
participants (1)
-
Giovanni Mascellani (@giomasce)