diff options
Diffstat (limited to 'src/mesa/shader/slang/library/slang_shader.syn')
-rw-r--r-- | src/mesa/shader/slang/library/slang_shader.syn | 21 |
1 files changed, 16 insertions, 5 deletions
diff --git a/src/mesa/shader/slang/library/slang_shader.syn b/src/mesa/shader/slang/library/slang_shader.syn index 149bb15c44..9389869da2 100644 --- a/src/mesa/shader/slang/library/slang_shader.syn +++ b/src/mesa/shader/slang/library/slang_shader.syn @@ -139,8 +139,10 @@ .emtcode TYPE_SPECIFIER_SAMPLERCUBE 19 .emtcode TYPE_SPECIFIER_SAMPLER1DSHADOW 20 .emtcode TYPE_SPECIFIER_SAMPLER2DSHADOW 21 -.emtcode TYPE_SPECIFIER_STRUCT 22 -.emtcode TYPE_SPECIFIER_TYPENAME 23 +.emtcode TYPE_SPECIFIER_SAMPLER2DRECT 22 +.emtcode TYPE_SPECIFIER_SAMPLER2DRECTSHADOW 23 +.emtcode TYPE_SPECIFIER_STRUCT 24 +.emtcode TYPE_SPECIFIER_TYPENAME 25 /* structure field */ .emtcode FIELD_NONE 0 @@ -884,6 +886,8 @@ type_qualifier | "samplerCube" | "sampler1DShadow" | "sampler2DShadow" + | "sampler2DRect" + | "sampler2DRectShadow" | <struct_specifier> | <type_name> */ @@ -910,6 +914,8 @@ type_specifier_space "samplerCube" .emit TYPE_SPECIFIER_SAMPLERCUBE .or "sampler1DShadow" .emit TYPE_SPECIFIER_SAMPLER1DSHADOW .or "sampler2DShadow" .emit TYPE_SPECIFIER_SAMPLER2DSHADOW .or + "sampler2DRect" .emit TYPE_SPECIFIER_SAMPLER2DRECT .or + "sampler2DRectShadow" .emit TYPE_SPECIFIER_SAMPLER2DRECTSHADOW .or type_name .emit TYPE_SPECIFIER_TYPENAME; type_specifier_nospace struct_specifier .emit TYPE_SPECIFIER_STRUCT; @@ -1096,7 +1102,7 @@ condition_3 expression .and .true .emit OP_END; /* - <iteration_statement> ::= "while" "(" <condition> ")" <statement_no_new_scope> + <iteration_statement> ::= "while" "(" <condition> ")" <statement> | "do" <statement> "while" "(" <expression> ")" ";" | "for" "(" <for_init_statement> <for_rest_statement> ")" <statement_no_new_scope> @@ -1105,7 +1111,7 @@ iteration_statement iteration_statement_1 .or iteration_statement_2 .or iteration_statement_3; iteration_statement_1 "while" .emit OP_WHILE .and lparen .error LPAREN_EXPECTED .and condition .and - rparen .error RPAREN_EXPECTED .and statement_no_new_scope; + rparen .error RPAREN_EXPECTED .and statement; iteration_statement_2 "do" .emit OP_DO .and statement_space .and "while" .and lparen .error LPAREN_EXPECTED .and expression .and rparen .error RPAREN_EXPECTED .emit OP_END .and semicolon; @@ -1192,7 +1198,12 @@ note: this is an extension to the standard language specification - normally sla __asm statements */ asm_argument - variable_identifier .or floatconstant; + var_with_field .or + variable_identifier .or + floatconstant; + +var_with_field + variable_identifier .and dot .and field_selection .emit OP_FIELD; /* <translation_unit> ::= <external_declaration> |