Zebediah Figura (@zfigura) commented about libs/vkd3d-shader/hlsl.y:
+static bool add_technique(struct hlsl_ctx *ctx, const char *name, const char *typename,
const struct vkd3d_shader_location *loc)
+{
- struct hlsl_ir_var *var;
- struct hlsl_type *type;
- type = hlsl_get_type(ctx->globals, typename, false, false);
- if (!(var = hlsl_new_var(ctx, name, type, loc, NULL, 0, NULL)))
return false;
- if (!hlsl_add_var(ctx, var, false))
- {
struct hlsl_ir_var *old = hlsl_get_var(ctx->cur_scope, var->name);
hlsl_error(ctx, &var->loc, VKD3D_SHADER_ERROR_HLSL_REDEFINED,
"Variable \"%s\" was already declared in this scope.", var->name);
Technique %s