diff options
author | Alan Hourihane <[email protected]> | 2009-01-14 23:33:41 +0000 |
---|---|---|
committer | Alan Hourihane <[email protected]> | 2009-01-14 23:33:41 +0000 |
commit | 658b1bdb1cc5f9910be910dc156a2e81ed999756 (patch) | |
tree | 98d15bcf83b662dd8c7186dd423e3d8ebbd87f1c /src/mesa/shader/slang/library/slang_pp_directives.syn | |
parent | e82784559e00cb534993c01309ad1832e9b3e56b (diff) | |
parent | 03188b09e071ace9d9e21ccc56c01e90c0fa8639 (diff) |
Merge commit 'origin/master' into gallium-0.2
Conflicts:
docs/install.html
docs/relnotes-7.3.html
src/mesa/shader/slang/slang_codegen.c
src/mesa/shader/slang/slang_compile.c
src/mesa/shader/slang/slang_emit.c
src/mesa/shader/slang/slang_preprocess.c
src/mesa/shader/slang/slang_preprocess.h
Diffstat (limited to 'src/mesa/shader/slang/library/slang_pp_directives.syn')
-rw-r--r-- | src/mesa/shader/slang/library/slang_pp_directives.syn | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/src/mesa/shader/slang/library/slang_pp_directives.syn b/src/mesa/shader/slang/library/slang_pp_directives.syn index d4a321034d1..b51d168cc03 100644 --- a/src/mesa/shader/slang/library/slang_pp_directives.syn +++ b/src/mesa/shader/slang/library/slang_pp_directives.syn @@ -79,6 +79,12 @@ .emtcode BEHAVIOR_WARN 3 .emtcode BEHAVIOR_DISABLE 4 +/* + * The PRAGMA_* symbols follow TOKEN_PRAGMA + */ +.emtcode PRAGMA_NO_PARAM 0 +.emtcode PRAGMA_PARAM 1 + source optional_directive .and .loop source_element .and '\0' .emit ESCAPE_TOKEN .emit TOKEN_END; @@ -153,6 +159,7 @@ directive dir_elif .emit TOKEN_ELIF .or dir_endif .emit TOKEN_ENDIF .or dir_ext .emit TOKEN_EXTENSION .or + dir_pragma .emit TOKEN_PRAGMA .or dir_line .emit TOKEN_LINE; dir_define @@ -187,6 +194,19 @@ dir_ext dir_line optional_space .and '#' .and optional_space .and "line" .and expression; +dir_pragma + optional_space .and '#' .and optional_space .and "pragma" .and symbol .and opt_pragma_param; + + +opt_pragma_param + pragma_param .or .true .emit PRAGMA_NO_PARAM; + +pragma_param + optional_space .and '(' .emit PRAGMA_PARAM .and optional_space .and symbol_no_space .and optional_space .and ')'; + +symbol_no_space + symbol_character .emit * .and .loop symbol_character2 .emit * .and .true .emit '\0'; + symbol space .and symbol_character .emit * .and .loop symbol_character2 .emit * .and .true .emit '\0'; |