mirror of
https://gitlab.winehq.org/wine/vkd3d.git
synced 2024-11-21 16:46:41 -08:00
vkd3d-shader/hlsl: Parse empty technique declarations.
Signed-off-by: Nikolay Sivov <nsivov@codeweavers.com>
This commit is contained in:
parent
53b0101a53
commit
dbcc4c4e40
Notes:
Alexandre Julliard
2023-11-02 22:50:16 +01:00
Approved-by: Giovanni Mascellani (@giomasce) Approved-by: Henri Verbeet (@hverbeet) Approved-by: Zebediah Figura (@zfigura) Approved-by: Alexandre Julliard (@julliard) Merge-Request: https://gitlab.winehq.org/wine/vkd3d/-/merge_requests/437
@ -4955,6 +4955,7 @@ static void check_duplicated_switch_cases(struct hlsl_ctx *ctx, const struct hls
|
||||
|
||||
%type <name> any_identifier
|
||||
%type <name> var_identifier
|
||||
%type <name> technique_name
|
||||
|
||||
%type <parameter> parameter
|
||||
|
||||
@ -4996,8 +4997,50 @@ hlsl_prog:
|
||||
destroy_block($2);
|
||||
}
|
||||
| hlsl_prog preproc_directive
|
||||
| hlsl_prog technique
|
||||
| hlsl_prog ';'
|
||||
|
||||
technique_name:
|
||||
%empty
|
||||
{
|
||||
$$ = NULL;
|
||||
}
|
||||
| any_identifier
|
||||
|
||||
pass_list:
|
||||
%empty
|
||||
|
||||
technique9:
|
||||
KW_TECHNIQUE technique_name '{' pass_list '}'
|
||||
{
|
||||
hlsl_fixme(ctx, &@$, "Unsupported \'technique\' declaration.");
|
||||
}
|
||||
|
||||
technique10:
|
||||
KW_TECHNIQUE10 technique_name '{' pass_list '}'
|
||||
{
|
||||
if (ctx->profile->type == VKD3D_SHADER_TYPE_EFFECT && ctx->profile->major_version == 2)
|
||||
hlsl_error(ctx, &@1, VKD3D_SHADER_ERROR_HLSL_INVALID_SYNTAX,
|
||||
"The 'technique10' keyword is invalid for this profile.");
|
||||
|
||||
hlsl_fixme(ctx, &@$, "Unsupported \'technique10\' declaration.");
|
||||
}
|
||||
|
||||
technique11:
|
||||
KW_TECHNIQUE11 technique_name '{' pass_list '}'
|
||||
{
|
||||
if (ctx->profile->type == VKD3D_SHADER_TYPE_EFFECT && ctx->profile->major_version == 2)
|
||||
hlsl_error(ctx, &@1, VKD3D_SHADER_ERROR_HLSL_INVALID_SYNTAX,
|
||||
"The 'technique11' keyword is invalid for this profile.");
|
||||
|
||||
hlsl_fixme(ctx, &@$, "Unsupported \'technique11\' declaration.");
|
||||
}
|
||||
|
||||
technique:
|
||||
technique9
|
||||
| technique10
|
||||
| technique11
|
||||
|
||||
buffer_declaration:
|
||||
buffer_type any_identifier colon_attribute
|
||||
{
|
||||
|
@ -76,7 +76,7 @@ technique10
|
||||
float4 f;
|
||||
|
||||
% fx_5_0 keyword fails with fx_2_0 profile
|
||||
[effect fail]
|
||||
[effect fail todo]
|
||||
technique
|
||||
{
|
||||
}
|
||||
@ -85,7 +85,7 @@ technique11
|
||||
{
|
||||
}
|
||||
|
||||
[effect fail]
|
||||
[effect fail todo]
|
||||
technique
|
||||
{
|
||||
}
|
||||
@ -94,7 +94,7 @@ tEchnique10
|
||||
{
|
||||
}
|
||||
|
||||
[effect fail]
|
||||
[effect fail todo]
|
||||
technique
|
||||
{
|
||||
}
|
||||
|
@ -46,7 +46,7 @@ technique11
|
||||
{
|
||||
}
|
||||
|
||||
[effect fail]
|
||||
[effect fail todo]
|
||||
technique
|
||||
{
|
||||
}
|
||||
@ -55,7 +55,7 @@ tEchnique10
|
||||
{
|
||||
}
|
||||
|
||||
[effect fail]
|
||||
[effect fail todo]
|
||||
technique
|
||||
{
|
||||
}
|
||||
|
@ -46,7 +46,7 @@ technique11
|
||||
{
|
||||
}
|
||||
|
||||
[effect fail]
|
||||
[effect fail todo]
|
||||
technique
|
||||
{
|
||||
}
|
||||
@ -55,7 +55,7 @@ tEchnique10
|
||||
{
|
||||
}
|
||||
|
||||
[effect fail]
|
||||
[effect fail todo]
|
||||
technique
|
||||
{
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user