Zebediah Figura (@zfigura) commented about libs/vkd3d-shader/hlsl.y:
hlsl_block_add_instr($$, s);
}
+switch_case:
KW_CASE expr ':' statement_list
{
struct hlsl_ir_switch_case *c;
c = hlsl_new_switch_case(ctx, $2, $4, &@2);
destroy_block($2);
destroy_block($4);
if (!c)
YYABORT;
$$ = &c->entry;
Why doesn't this rule just return a 'struct hlsl_ir_switch_case *'?