1 static char arb_grammar_text
[] = ".syntax program;\n"
2 ".emtcode REVISION 0x03\n"
3 ".emtcode FRAGMENT_PROGRAM 0x01\n"
4 ".emtcode VERTEX_PROGRAM 0x02\n"
5 ".emtcode OPTION 0x01\n"
6 ".emtcode INSTRUCTION 0x02\n"
7 ".emtcode DECLARATION 0x03\n"
9 ".emtcode ARB_PRECISION_HINT_FASTEST 0x01\n"
10 ".emtcode ARB_PRECISION_HINT_NICEST 0x02\n"
11 ".emtcode ARB_FOG_EXP 0x04\n"
12 ".emtcode ARB_FOG_EXP2 0x08\n"
13 ".emtcode ARB_FOG_LINEAR 0x10\n"
14 ".emtcode ARB_POSITION_INVARIANT 0x01\n"
15 ".emtcode F_ALU_INST 0x01\n"
16 ".emtcode F_TEX_INST 0x02\n"
17 ".emtcode F_ALU_VECTOR 0x01\n"
18 ".emtcode F_ALU_SCALAR 0x02\n"
19 ".emtcode F_ALU_BINSC 0x03\n"
20 ".emtcode F_ALU_BIN 0x04\n"
21 ".emtcode F_ALU_TRI 0x05\n"
22 ".emtcode F_ALU_SWZ 0x06\n"
23 ".emtcode F_TEX_SAMPLE 0x07\n"
24 ".emtcode F_TEX_KIL 0x08\n"
25 ".emtcode V_GEN_ARL 0x01\n"
26 ".emtcode V_GEN_VECTOR 0x02\n"
27 ".emtcode V_GEN_SCALAR 0x03\n"
28 ".emtcode V_GEN_BINSC 0x04\n"
29 ".emtcode V_GEN_BIN 0x05\n"
30 ".emtcode V_GEN_TRI 0x06\n"
31 ".emtcode V_GEN_SWZ 0x07\n"
32 ".emtcode F_ABS 0x00\n"
33 ".emtcode F_ABS_SAT 0x01\n"
34 ".emtcode F_FLR 0x02\n"
35 ".emtcode F_FLR_SAT 0x03\n"
36 ".emtcode F_FRC 0x04\n"
37 ".emtcode F_FRC_SAT 0x05\n"
38 ".emtcode F_LIT 0x06\n"
39 ".emtcode F_LIT_SAT 0x07\n"
40 ".emtcode F_MOV 0x08\n"
41 ".emtcode F_MOV_SAT 0x09\n"
42 ".emtcode F_COS 0x0A\n"
43 ".emtcode F_COS_SAT 0x0B\n"
44 ".emtcode F_EX2 0x0C\n"
45 ".emtcode F_EX2_SAT 0x0D\n"
46 ".emtcode F_LG2 0x0E\n"
47 ".emtcode F_LG2_SAT 0x0F\n"
48 ".emtcode F_RCP 0x10\n"
49 ".emtcode F_RCP_SAT 0x11\n"
50 ".emtcode F_RSQ 0x12\n"
51 ".emtcode F_RSQ_SAT 0x13\n"
52 ".emtcode F_SIN 0x14\n"
53 ".emtcode F_SIN_SAT 0x15\n"
54 ".emtcode F_SCS 0x16\n"
55 ".emtcode F_SCS_SAT 0x17\n"
56 ".emtcode F_POW 0x18\n"
57 ".emtcode F_POW_SAT 0x19\n"
58 ".emtcode F_ADD 0x1A\n"
59 ".emtcode F_ADD_SAT 0x1B\n"
60 ".emtcode F_DP3 0x1C\n"
61 ".emtcode F_DP3_SAT 0x1D\n"
62 ".emtcode F_DP4 0x1E\n"
63 ".emtcode F_DP4_SAT 0x1F\n"
64 ".emtcode F_DPH 0x20\n"
65 ".emtcode F_DPH_SAT 0x21\n"
66 ".emtcode F_DST 0x22\n"
67 ".emtcode F_DST_SAT 0x23\n"
68 ".emtcode F_MAX 0x24\n"
69 ".emtcode F_MAX_SAT 0x25\n"
70 ".emtcode F_MIN 0x26\n"
71 ".emtcode F_MIN_SAT 0x27\n"
72 ".emtcode F_MUL 0x28\n"
73 ".emtcode F_MUL_SAT 0x29\n"
74 ".emtcode F_SGE 0x2A\n"
75 ".emtcode F_SGE_SAT 0x2B\n"
76 ".emtcode F_SLT 0x2C\n"
77 ".emtcode F_SLT_SAT 0x2D\n"
78 ".emtcode F_SUB 0x2E\n"
79 ".emtcode F_SUB_SAT 0x2F\n"
80 ".emtcode F_XPD 0x30\n"
81 ".emtcode F_XPD_SAT 0x31\n"
82 ".emtcode F_CMP 0x32\n"
83 ".emtcode F_CMP_SAT 0x33\n"
84 ".emtcode F_LRP 0x34\n"
85 ".emtcode F_LRP_SAT 0x35\n"
86 ".emtcode F_MAD 0x36\n"
87 ".emtcode F_MAD_SAT 0x37\n"
88 ".emtcode F_SWZ 0x38\n"
89 ".emtcode F_SWZ_SAT 0x39\n"
90 ".emtcode F_TEX 0x3A\n"
91 ".emtcode F_TEX_SAT 0x3B\n"
92 ".emtcode F_TXB 0x3C\n"
93 ".emtcode F_TXB_SAT 0x3D\n"
94 ".emtcode F_TXP 0x3E\n"
95 ".emtcode F_TXP_SAT 0x3F\n"
96 ".emtcode F_KIL 0x40\n"
97 ".emtcode V_ARL 0x01\n"
98 ".emtcode V_ABS 0x02\n"
99 ".emtcode V_FLR 0x03\n"
100 ".emtcode V_FRC 0x04\n"
101 ".emtcode V_LIT 0x05\n"
102 ".emtcode V_MOV 0x06\n"
103 ".emtcode V_EX2 0x07\n"
104 ".emtcode V_EXP 0x08\n"
105 ".emtcode V_LG2 0x09\n"
106 ".emtcode V_LOG 0x0A\n"
107 ".emtcode V_RCP 0x0B\n"
108 ".emtcode V_RSQ 0x0C\n"
109 ".emtcode V_POW 0x0D\n"
110 ".emtcode V_ADD 0x0E\n"
111 ".emtcode V_DP3 0x0F\n"
112 ".emtcode V_DP4 0x10\n"
113 ".emtcode V_DPH 0x11\n"
114 ".emtcode V_DST 0x12\n"
115 ".emtcode V_MAX 0x13\n"
116 ".emtcode V_MIN 0x14\n"
117 ".emtcode V_MUL 0x15\n"
118 ".emtcode V_SGE 0x16\n"
119 ".emtcode V_SLT 0x17\n"
120 ".emtcode V_SUB 0x18\n"
121 ".emtcode V_XPD 0x19\n"
122 ".emtcode V_MAD 0x1A\n"
123 ".emtcode V_SWZ 0x1B\n"
124 ".emtcode FRAGMENT_ATTRIB_COLOR 0x01\n"
125 ".emtcode FRAGMENT_ATTRIB_TEXCOORD 0x02\n"
126 ".emtcode FRAGMENT_ATTRIB_FOGCOORD 0x03\n"
127 ".emtcode FRAGMENT_ATTRIB_POSITION 0x04\n"
128 ".emtcode VERTEX_ATTRIB_POSITION 0x01\n"
129 ".emtcode VERTEX_ATTRIB_WEIGHT 0x02\n"
130 ".emtcode VERTEX_ATTRIB_NORMAL 0x03\n"
131 ".emtcode VERTEX_ATTRIB_COLOR 0x04\n"
132 ".emtcode VERTEX_ATTRIB_FOGCOORD 0x05\n"
133 ".emtcode VERTEX_ATTRIB_TEXCOORD 0x06\n"
134 ".emtcode VERTEX_ATTRIB_MATRIXINDEX 0x07\n"
135 ".emtcode VERTEX_ATTRIB_GENERIC 0x08\n"
136 ".emtcode FRAGMENT_RESULT_COLOR 0x01\n"
137 ".emtcode FRAGMENT_RESULT_DEPTH 0x02\n"
138 ".emtcode VERTEX_RESULT_POSITION 0x01\n"
139 ".emtcode VERTEX_RESULT_COLOR 0x02\n"
140 ".emtcode VERTEX_RESULT_FOGCOORD 0x03\n"
141 ".emtcode VERTEX_RESULT_POINTSIZE 0x04\n"
142 ".emtcode VERTEX_RESULT_TEXCOORD 0x05\n"
143 ".emtcode TEXTARGET_1D 0x01\n"
144 ".emtcode TEXTARGET_2D 0x02\n"
145 ".emtcode TEXTARGET_3D 0x03\n"
146 ".emtcode TEXTARGET_RECT 0x04\n"
147 ".emtcode TEXTARGET_CUBE 0x05\n"
148 ".emtcode FACE_FRONT 0x00\n"
149 ".emtcode FACE_BACK 0x01\n"
150 ".emtcode COLOR_PRIMARY 0x00\n"
151 ".emtcode COLOR_SECONDARY 0x01\n"
152 ".emtcode COMPONENT_X 0x00\n"
153 ".emtcode COMPONENT_Y 0x01\n"
154 ".emtcode COMPONENT_Z 0x02\n"
155 ".emtcode COMPONENT_W 0x03\n"
156 ".emtcode COMPONENT_0 0x04\n"
157 ".emtcode COMPONENT_1 0x05\n"
158 ".emtcode ARRAY_INDEX_ABSOLUTE 0x00\n"
159 ".emtcode ARRAY_INDEX_RELATIVE 0x01\n"
160 ".emtcode MATRIX_MODELVIEW 0x01\n"
161 ".emtcode MATRIX_PROJECTION 0x02\n"
162 ".emtcode MATRIX_MVP 0x03\n"
163 ".emtcode MATRIX_TEXTURE 0x04\n"
164 ".emtcode MATRIX_PALETTE 0x05\n"
165 ".emtcode MATRIX_PROGRAM 0x06\n"
166 ".emtcode MATRIX_MODIFIER_IDENTITY 0x00\n"
167 ".emtcode MATRIX_MODIFIER_INVERSE 0x01\n"
168 ".emtcode MATRIX_MODIFIER_TRANSPOSE 0x02\n"
169 ".emtcode MATRIX_MODIFIER_INVTRANS 0x03\n"
170 ".emtcode CONSTANT_SCALAR 0x01\n"
171 ".emtcode CONSTANT_VECTOR 0x02\n"
172 ".emtcode PROGRAM_PARAM_ENV 0x01\n"
173 ".emtcode PROGRAM_PARAM_LOCAL 0x02\n"
174 ".emtcode REGISTER_ATTRIB 0x01\n"
175 ".emtcode REGISTER_PARAM 0x02\n"
176 ".emtcode REGISTER_RESULT 0x03\n"
177 ".emtcode REGISTER_ESTABLISHED_NAME 0x04\n"
178 ".emtcode PARAM_NULL 0x00\n"
179 ".emtcode PARAM_ARRAY_ELEMENT 0x01\n"
180 ".emtcode PARAM_STATE_ELEMENT 0x02\n"
181 ".emtcode PARAM_PROGRAM_ELEMENT 0x03\n"
182 ".emtcode PARAM_PROGRAM_ELEMENTS 0x04\n"
183 ".emtcode PARAM_CONSTANT 0x05\n"
184 ".emtcode STATE_MATERIAL 0x01\n"
185 ".emtcode STATE_LIGHT 0x02\n"
186 ".emtcode STATE_LIGHT_MODEL 0x03\n"
187 ".emtcode STATE_LIGHT_PROD 0x04\n"
188 ".emtcode STATE_FOG 0x05\n"
189 ".emtcode STATE_MATRIX_ROWS 0x06\n"
190 ".emtcode STATE_TEX_ENV 0x07\n"
191 ".emtcode STATE_DEPTH 0x08\n"
192 ".emtcode STATE_TEX_GEN 0x07\n"
193 ".emtcode STATE_CLIP_PLANE 0x08\n"
194 ".emtcode STATE_POINT 0x09\n"
195 ".emtcode MATERIAL_AMBIENT 0x01\n"
196 ".emtcode MATERIAL_DIFFUSE 0x02\n"
197 ".emtcode MATERIAL_SPECULAR 0x03\n"
198 ".emtcode MATERIAL_EMISSION 0x04\n"
199 ".emtcode MATERIAL_SHININESS 0x05\n"
200 ".emtcode LIGHT_AMBIENT 0x01\n"
201 ".emtcode LIGHT_DIFFUSE 0x02\n"
202 ".emtcode LIGHT_SPECULAR 0x03\n"
203 ".emtcode LIGHT_POSITION 0x04\n"
204 ".emtcode LIGHT_ATTENUATION 0x05\n"
205 ".emtcode LIGHT_HALF 0x06\n"
206 ".emtcode LIGHT_SPOT_DIRECTION 0x07\n"
207 ".emtcode LIGHT_MODEL_AMBIENT 0x01\n"
208 ".emtcode LIGHT_MODEL_SCENECOLOR 0x02\n"
209 ".emtcode LIGHT_PROD_AMBIENT 0x01\n"
210 ".emtcode LIGHT_PROD_DIFFUSE 0x02\n"
211 ".emtcode LIGHT_PROD_SPECULAR 0x03\n"
212 ".emtcode TEX_ENV_COLOR 0x01\n"
213 ".emtcode TEX_GEN_EYE 0x01\n"
214 ".emtcode TEX_GEN_OBJECT 0x02\n"
215 ".emtcode FOG_COLOR 0x01\n"
216 ".emtcode FOG_PARAMS 0x02\n"
217 ".emtcode DEPTH_RANGE 0x01\n"
218 ".emtcode POINT_SIZE 0x01\n"
219 ".emtcode POINT_ATTENUATION 0x02\n"
220 ".emtcode ATTRIB 0x01\n"
221 ".emtcode PARAM 0x02\n"
222 ".emtcode TEMP 0x03\n"
223 ".emtcode OUTPUT 0x04\n"
224 ".emtcode ALIAS 0x05\n"
225 ".emtcode ADDRESS 0x06\n"
226 ".errtext UNKNOWN_PROGRAM_SIGNATURE \"1001: '$e_signature$': unknown program signature\"\n"
227 ".errtext MISSING_END_OR_INVALID_STATEMENT \"1002: '$e_statement$': invalid statement\"\n"
228 ".errtext CODE_AFTER_END \"1003: '$e_statement$': code after 'END' keyword\"\n"
229 ".errtext INVALID_PROGRAM_OPTION \"1004: '$e_identifier$': invalid program option\"\n"
230 ".errtext EXT_SWIZ_COMP_EXPECTED \"1005: extended swizzle component expected but '$e_token$' found\"\n"
231 ".errtext TEX_TARGET_EXPECTED \"1006: texture target expected but '$e_token$' found\"\n"
232 ".errtext TEXTURE_EXPECTED \"1007: 'texture' expected but '$e_identifier$' found\"\n"
233 ".errtext SOURCE_REGISTER_EXPECTED \"1008: source register expected but '$e_token$' found\"\n"
234 ".errtext DESTINATION_REGISTER_EXPECTED \"1009: destination register expected but '$e_token$' found\"\n"
235 ".errtext INVALID_ADDRESS_COMPONENT \"1010: '$e_identifier$': invalid address component\"\n"
236 ".errtext INVALID_ADDRESS_WRITEMASK \"1011: '$e_identifier$': invalid address writemask\"\n"
237 ".errtext INVALID_COMPONENT \"1012: '$e_charordigit$': invalid component\"\n"
238 ".errtext INVALID_SUFFIX \"1013: '$e_identifier$': invalid suffix\"\n"
239 ".errtext INVALID_WRITEMASK \"1014: '$e_identifier$': invalid writemask\"\n"
240 ".errtext FRAGMENT_EXPECTED \"1015: 'fragment' expected but '$e_identifier$' found\"\n"
241 ".errtext VERTEX_EXPECTED \"1016: 'vertex' expected but '$e_identifier$' found\"\n"
242 ".errtext INVALID_FRAGMENT_PROPERTY \"1017: '$e_identifier$': invalid fragment property\"\n"
243 ".errtext INVALID_VERTEX_PROPERTY \"1018: '$e_identifier$': invalid vertex property\"\n"
244 ".errtext INVALID_STATE_PROPERTY \"1019: '$e_identifier$': invalid state property\"\n"
245 ".errtext INVALID_MATERIAL_PROPERTY \"1020: '$e_identifier$': invalid material property\"\n"
246 ".errtext INVALID_LIGHT_PROPERTY \"1021: '$e_identifier$': invalid light property\"\n"
247 ".errtext INVALID_SPOT_PROPERTY \"1022: '$e_identifier$': invalid spot property\"\n"
248 ".errtext INVALID_LIGHTMODEL_PROPERTY \"1023: '$e_identifier$': invalid light model property\"\n"
249 ".errtext INVALID_LIGHTPROD_PROPERTY \"1024: '$e_identifier$': invalid light product property\"\n"
250 ".errtext INVALID_TEXENV_PROPERTY \"1025: '$e_identifier$': invalid texture environment property\"\n"
251 ".errtext INVALID_TEXGEN_PROPERTY \"1026: '$e_identifier$': invalid texture generating property\"\n"
252 ".errtext INVALID_TEXGEN_COORD \"1027: '$e_identifier$': invalid texture generating coord\"\n"
253 ".errtext INVALID_FOG_PROPERTY \"1028: '$e_identifier$': invalid fog property\"\n"
254 ".errtext INVALID_DEPTH_PROPERTY \"1029: '$e_identifier$': invalid depth property\"\n"
255 ".errtext INVALID_CLIPPLANE_PROPERTY \"1030: '$e_identifier$': invalid clip plane property\"\n"
256 ".errtext INVALID_POINT_PROPERTY \"1031: '$e_identifier$': invalid point property\"\n"
257 ".errtext MATRIX_ROW_SELECTOR_OR_MODIFIER_EXPECTED \"1032: matrix row selector or modifier expected but '$e_token$' found\"\n"
258 ".errtext INVALID_MATRIX_NAME \"1033: '$e_identifier$': invalid matrix name\"\n"
259 ".errtext INVALID_PROGRAM_PROPERTY \"1034: '$e_identifier$': invalid program property\"\n"
260 ".errtext RESULT_EXPECTED \"1035: 'result' expected but '$e_token$' found\"\n"
261 ".errtext INVALID_RESULT_PROPERTY \"1036: '$e_identifier$': invalid result property\"\n"
262 ".errtext INVALID_FACE_PROPERTY \"1037: '$e_identifier$': invalid face property\"\n"
263 ".errtext INVALID_COLOR_PROPERTY \"1038: '$e_identifier$': invalid color property\"\n"
264 ".errtext IDENTIFIER_EXPECTED \"1039: identifier expected but '$e_token$' found\"\n"
265 ".errtext RESERVED_KEYWORD \"1040: use of reserved keyword as an identifier\"\n"
266 ".errtext INTEGER_EXPECTED \"1041: integer value expected but '$e_token$' found\"\n"
267 ".errtext MISSING_SEMICOLON \"1042: ';' expected but '$e_token$' found\"\n"
268 ".errtext MISSING_COMMA \"1043: ',' expected but '$e_token$' found\"\n"
269 ".errtext MISSING_LBRACKET \"1044: '[' expected but '$e_token$' found\"\n"
270 ".errtext MISSING_RBRACKET \"1045: ']' expected but '$e_token$' found\"\n"
271 ".errtext MISSING_DOT \"1046: '.' expected but '$e_token$' found\"\n"
272 ".errtext MISSING_EQUAL \"1047: '=' expected but '$e_token$' found\"\n"
273 ".errtext MISSING_LBRACE \"1048: '{' expected but '$e_token$' found\"\n"
274 ".errtext MISSING_RBRACE \"1049: '}' expected but '$e_token$' found\"\n"
275 ".errtext MISSING_DOTDOT \"1050: '..' expected but '$e_token$' found\"\n"
276 ".errtext MISSING_FRACTION_OR_EXPONENT \"1051: missing fraction part or exponent\"\n"
277 ".errtext MISSING_DOT_OR_EXPONENT \"1052: missing '.' or exponent\"\n"
278 ".errtext EXPONENT_VALUE_EXPECTED \"1053: exponent value expected\"\n"
280 " programs .error UNKNOWN_PROGRAM_SIGNATURE .emit REVISION;\n"
282 " frag_program_1_0 .emit FRAGMENT_PROGRAM .emit 0x01 .emit 0x00 .or\n"
283 " vert_program_1_0 .emit VERTEX_PROGRAM .emit 0x01 .emit 0x00;\n"
285 " '!' .and '!' .and 'A' .and 'R' .and 'B' .and 'f' .and 'p' .and '1' .and '.' .and '0' .and\n"
286 " optional_space .and fp_optionSequence .and fp_statementSequence .and\n"
287 " \"END\" .error MISSING_END_OR_INVALID_STATEMENT .emit END .and optional_space .and\n"
288 " '\\0' .error CODE_AFTER_END;\n"
290 " '!' .and '!' .and 'A' .and 'R' .and 'B' .and 'v' .and 'p' .and '1' .and '.' .and '0' .and\n"
291 " optional_space .and vp_optionSequence .and vp_statementSequence .and\n"
292 " \"END\" .error MISSING_END_OR_INVALID_STATEMENT .emit END .and optional_space .and\n"
293 " '\\0' .error CODE_AFTER_END;\n"
294 "fp_optionSequence\n"
295 " .loop fp_option;\n"
296 "vp_optionSequence\n"
297 " .loop vp_option;\n"
299 " \"OPTION\" .emit OPTION .and space .and fp_optionString .error INVALID_PROGRAM_OPTION .and\n"
302 " \"OPTION\" .emit OPTION .and space .and vp_optionString .error INVALID_PROGRAM_OPTION .and\n"
305 " \"ARB_precision_hint_fastest\" .emit ARB_PRECISION_HINT_FASTEST .or\n"
306 " \"ARB_precision_hint_nicest\" .emit ARB_PRECISION_HINT_NICEST .or\n"
307 " \"ARB_fog_exp\" .emit ARB_FOG_EXP .or\n"
308 " \"ARB_fog_exp2\" .emit ARB_FOG_EXP2 .or\n"
309 " \"ARB_fog_linear\" .emit ARB_FOG_LINEAR;\n"
311 " \"ARB_position_invariant\" .emit ARB_POSITION_INVARIANT;\n"
312 "fp_statementSequence\n"
313 " .loop fp_statement;\n"
314 "vp_statementSequence\n"
315 " .loop vp_statement;\n"
317 " fp_statement_1 .or fp_statement_2;\n"
319 " vp_statement_1 .or vp_statement_2;\n"
321 " fp_instruction .emit INSTRUCTION .emit $ .and semicolon;\n"
323 " fp_namingStatement .emit DECLARATION .and semicolon;\n"
325 " vp_instruction .emit INSTRUCTION .emit $ .and semicolon;\n"
327 " vp_namingStatement .emit DECLARATION .and semicolon;\n"
329 " ALUInstruction .emit F_ALU_INST .or\n"
330 " TexInstruction .emit F_TEX_INST;\n"
332 " ARL_instruction .emit V_GEN_ARL .or\n"
333 " vp_VECTORop_instruction .emit V_GEN_VECTOR .or\n"
334 " vp_SCALARop_instruction .emit V_GEN_SCALAR .or\n"
335 " vp_BINSCop_instruction .emit V_GEN_BINSC .or\n"
336 " vp_BINop_instruction .emit V_GEN_BIN .or\n"
337 " vp_TRIop_instruction .emit V_GEN_TRI .or\n"
338 " vp_SWZ_instruction .emit V_GEN_SWZ;\n"
340 " fp_VECTORop_instruction .emit F_ALU_VECTOR .or\n"
341 " fp_SCALARop_instruction .emit F_ALU_SCALAR .or\n"
342 " fp_BINSCop_instruction .emit F_ALU_BINSC .or\n"
343 " fp_BINop_instruction .emit F_ALU_BIN .or\n"
344 " fp_TRIop_instruction .emit F_ALU_TRI .or\n"
345 " fp_SWZ_instruction .emit F_ALU_SWZ;\n"
347 " SAMPLE_instruction .emit F_TEX_SAMPLE .or\n"
348 " KIL_instruction .emit F_TEX_KIL;\n"
350 " \"ARL\" .emit V_ARL .and space .and maskedAddrReg .and comma .and vp_scalarSrcReg;\n"
351 "fp_VECTORop_instruction\n"
352 " fp_VECTORop .and space .and fp_maskedDstReg .and comma .and vectorSrcReg;\n"
353 "vp_VECTORop_instruction\n"
354 " vp_VECTORop .and space .and vp_maskedDstReg .and comma .and swizzleSrcReg;\n"
356 " \"ABS\" .emit F_ABS .or \"ABS_SAT\" .emit F_ABS_SAT .or\n"
357 " \"FLR\" .emit F_FLR .or \"FLR_SAT\" .emit F_FLR_SAT .or\n"
358 " \"FRC\" .emit F_FRC .or \"FRC_SAT\" .emit F_FRC_SAT .or\n"
359 " \"LIT\" .emit F_LIT .or \"LIT_SAT\" .emit F_LIT_SAT .or\n"
360 " \"MOV\" .emit F_MOV .or \"MOV_SAT\" .emit F_MOV_SAT;\n"
362 " \"ABS\" .emit V_ABS .or\n"
363 " \"FLR\" .emit V_FLR .or\n"
364 " \"FRC\" .emit V_FRC .or\n"
365 " \"LIT\" .emit V_LIT .or\n"
366 " \"MOV\" .emit V_MOV;\n"
367 "fp_SCALARop_instruction\n"
368 " fp_SCALARop .and space .and fp_maskedDstReg .and comma .and fp_scalarSrcReg;\n"
369 "vp_SCALARop_instruction\n"
370 " vp_SCALARop .and space .and vp_maskedDstReg .and comma .and vp_scalarSrcReg;\n"
372 " \"COS\" .emit F_COS .or \"COS_SAT\" .emit F_COS_SAT .or\n"
373 " \"EX2\" .emit F_EX2 .or \"EX2_SAT\" .emit F_EX2_SAT .or\n"
374 " \"LG2\" .emit F_LG2 .or \"LG2_SAT\" .emit F_LG2_SAT .or\n"
375 " \"RCP\" .emit F_RCP .or \"RCP_SAT\" .emit F_RCP_SAT .or\n"
376 " \"RSQ\" .emit F_RSQ .or \"RSQ_SAT\" .emit F_RSQ_SAT .or\n"
377 " \"SIN\" .emit F_SIN .or \"SIN_SAT\" .emit F_SIN_SAT .or\n"
378 " \"SCS\" .emit F_SCS .or \"SCS_SAT\" .emit F_SCS_SAT;\n"
380 " \"EX2\" .emit V_EX2 .or\n"
381 " \"EXP\" .emit V_EXP .or\n"
382 " \"LG2\" .emit V_LG2 .or\n"
383 " \"LOG\" .emit V_LOG .or\n"
384 " \"RCP\" .emit V_RCP .or\n"
385 " \"RSQ\" .emit V_RSQ;\n"
386 "fp_BINSCop_instruction\n"
387 " fp_BINSCop .and space .and fp_maskedDstReg .and comma .and fp_scalarSrcReg .and comma .and\n"
388 " fp_scalarSrcReg;\n"
389 "vp_BINSCop_instruction\n"
390 " vp_BINSCop .and space .and vp_maskedDstReg .and comma .and vp_scalarSrcReg .and comma .and\n"
391 " vp_scalarSrcReg;\n"
393 " \"POW\" .emit F_POW .or \"POW_SAT\" .emit F_POW_SAT;\n"
395 " \"POW\" .emit V_POW;\n"
396 "fp_BINop_instruction\n"
397 " fp_BINop .and space .and fp_maskedDstReg .and comma .and vectorSrcReg .and comma .and\n"
399 "vp_BINop_instruction\n"
400 " vp_BINop .and space .and vp_maskedDstReg .and comma .and swizzleSrcReg .and comma .and\n"
403 " \"ADD\" .emit F_ADD .or \"ADD_SAT\" .emit F_ADD_SAT .or\n"
404 " \"DP3\" .emit F_DP3 .or \"DP3_SAT\" .emit F_DP3_SAT .or\n"
405 " \"DP4\" .emit F_DP4 .or \"DP4_SAT\" .emit F_DP4_SAT .or\n"
406 " \"DPH\" .emit F_DPH .or \"DPH_SAT\" .emit F_DPH_SAT .or\n"
407 " \"DST\" .emit F_DST .or \"DST_SAT\" .emit F_DST_SAT .or\n"
408 " \"MAX\" .emit F_MAX .or \"MAX_SAT\" .emit F_MAX_SAT .or\n"
409 " \"MIN\" .emit F_MIN .or \"MIN_SAT\" .emit F_MIN_SAT .or\n"
410 " \"MUL\" .emit F_MUL .or \"MUL_SAT\" .emit F_MUL_SAT .or\n"
411 " \"SGE\" .emit F_SGE .or \"SGE_SAT\" .emit F_SGE_SAT .or\n"
412 " \"SLT\" .emit F_SLT .or \"SLT_SAT\" .emit F_SLT_SAT .or\n"
413 " \"SUB\" .emit F_SUB .or \"SUB_SAT\" .emit F_SUB_SAT .or\n"
414 " \"XPD\" .emit F_XPD .or \"XPD_SAT\" .emit F_XPD_SAT;\n"
416 " \"ADD\" .emit V_ADD .or\n"
417 " \"DP3\" .emit V_DP3 .or\n"
418 " \"DP4\" .emit V_DP4 .or\n"
419 " \"DPH\" .emit V_DPH .or\n"
420 " \"DST\" .emit V_DST .or\n"
421 " \"MAX\" .emit V_MAX .or\n"
422 " \"MIN\" .emit V_MIN .or\n"
423 " \"MUL\" .emit V_MUL .or\n"
424 " \"SGE\" .emit V_SGE .or\n"
425 " \"SLT\" .emit V_SLT .or\n"
426 " \"SUB\" .emit V_SUB .or\n"
427 " \"XPD\" .emit V_XPD;\n"
428 "fp_TRIop_instruction\n"
429 " fp_TRIop .and space .and fp_maskedDstReg .and comma .and vectorSrcReg .and comma .and\n"
430 " vectorSrcReg .and comma .and vectorSrcReg;\n"
431 "vp_TRIop_instruction\n"
432 " vp_TRIop .and space .and vp_maskedDstReg .and comma .and swizzleSrcReg .and comma .and\n"
433 " swizzleSrcReg .and comma .and swizzleSrcReg;\n"
435 " \"CMP\" .emit F_CMP .or \"CMP_SAT\" .emit F_CMP_SAT .or\n"
436 " \"LRP\" .emit F_LRP .or \"LRP_SAT\" .emit F_LRP_SAT .or\n"
437 " \"MAD\" .emit F_MAD .or \"MAD_SAT\" .emit F_MAD_SAT;\n"
439 " \"MAD\" .emit V_MAD;\n"
440 "fp_SWZ_instruction\n"
441 " SWZop .and space .and fp_maskedDstReg .and comma .and fp_srcReg .and comma .and\n"
442 " fp_extendedSwizzle .error EXT_SWIZ_COMP_EXPECTED;\n"
443 "vp_SWZ_instruction\n"
444 " \"SWZ\" .emit V_SWZ .and space .and vp_maskedDstReg .and comma .and vp_srcReg .and comma .and\n"
445 " vp_extendedSwizzle .error EXT_SWIZ_COMP_EXPECTED;\n"
447 " \"SWZ\" .emit F_SWZ .or \"SWZ_SAT\" .emit F_SWZ_SAT;\n"
448 "SAMPLE_instruction\n"
449 " SAMPLEop .and space .and fp_maskedDstReg .and comma .and vectorSrcReg .and comma .and\n"
450 " texImageUnit .and comma .and texTarget .error TEX_TARGET_EXPECTED;\n"
452 " \"TEX\" .emit F_TEX .or \"TEX_SAT\" .emit F_TEX_SAT .or\n"
453 " \"TXB\" .emit F_TXB .or \"TXB_SAT\" .emit F_TXB_SAT .or\n"
454 " \"TXP\" .emit F_TXP .or \"TXP_SAT\" .emit F_TXP_SAT;\n"
456 " \"KIL\" .emit F_KIL .and space .and vectorSrcReg;\n"
458 " \"texture\" .error TEXTURE_EXPECTED .and optTexImageUnitNum;\n"
460 " \"1D\" .emit TEXTARGET_1D .or\n"
461 " \"2D\" .emit TEXTARGET_2D .or\n"
462 " \"3D\" .emit TEXTARGET_3D .or\n"
463 " \"RECT\" .emit TEXTARGET_RECT .or\n"
464 " \"CUBE\" .emit TEXTARGET_CUBE;\n"
465 "optTexImageUnitNum\n"
466 " optTexImageUnitNum_1 .or .true .emit 0x00;\n"
467 "optTexImageUnitNum_1\n"
468 " lbracket_ne .and texImageUnitNum .and rbracket;\n"
472 " optionalSign .and fp_srcReg .and fp_scalarSuffix;\n"
474 " optionalSign .and vp_srcReg .and vp_scalarSuffix;\n"
476 " optionalSign .and vp_srcReg .and swizzleSuffix;\n"
478 " optionalSign .and fp_srcReg .and optionalSuffix;\n"
480 " fp_dstReg .and fp_optionalMask;\n"
482 " vp_dstReg .and vp_optionalMask;\n"
484 " addrReg .and addrWriteMask;\n"
485 "fp_extendedSwizzle\n"
486 " xyzwExtendedSwizzle .or rgbaExtendedSwizzle;\n"
487 "vp_extendedSwizzle\n"
488 " extSwizComp .and comma .and\n"
489 " extSwizComp .error EXT_SWIZ_COMP_EXPECTED .and comma .and\n"
490 " extSwizComp .error EXT_SWIZ_COMP_EXPECTED .and comma .and\n"
491 " extSwizComp .error EXT_SWIZ_COMP_EXPECTED;\n"
492 "xyzwExtendedSwizzle\n"
493 " xyzwExtSwizComp .and comma .and\n"
494 " xyzwExtSwizComp .error EXT_SWIZ_COMP_EXPECTED .and comma .and\n"
495 " xyzwExtSwizComp .error EXT_SWIZ_COMP_EXPECTED .and comma .and\n"
496 " xyzwExtSwizComp .error EXT_SWIZ_COMP_EXPECTED;\n"
497 "rgbaExtendedSwizzle\n"
498 " rgbaExtSwizComp .and comma .and\n"
499 " rgbaExtSwizComp .error EXT_SWIZ_COMP_EXPECTED .and comma .and\n"
500 " rgbaExtSwizComp .error EXT_SWIZ_COMP_EXPECTED .and comma .and\n"
501 " rgbaExtSwizComp .error EXT_SWIZ_COMP_EXPECTED;\n"
503 " optionalSign .and xyzwExtSwizSel;\n"
505 " optionalSign .and rgbaExtSwizSel;\n"
507 " optionalSign .and extSwizSel;\n"
509 " \"0\" .emit COMPONENT_0 .or \"1\" .emit COMPONENT_1 .or xyzwComponent_single;\n"
511 " \"0\" .emit COMPONENT_0 .or \"1\" .emit COMPONENT_1 .or rgbaComponent_single;\n"
513 " \"0\" .emit COMPONENT_0 .or \"1\" .emit COMPONENT_1 .or vp_component_single;\n"
515 " fp_srcReg_1 .error SOURCE_REGISTER_EXPECTED;\n"
517 " vp_srcReg_1 .error SOURCE_REGISTER_EXPECTED;\n"
519 " fragmentAttribReg .emit REGISTER_ATTRIB .or\n"
520 " fp_progParamReg .emit REGISTER_PARAM .or\n"
521 " fp_temporaryReg .emit REGISTER_ESTABLISHED_NAME;\n"
523 " vertexAttribReg .emit REGISTER_ATTRIB .or\n"
524 " vp_progParamReg .emit REGISTER_PARAM .or\n"
525 " vp_temporaryReg .emit REGISTER_ESTABLISHED_NAME;\n"
527 " fp_dstReg_1 .error DESTINATION_REGISTER_EXPECTED;\n"
529 " vp_dstReg_1 .error DESTINATION_REGISTER_EXPECTED;\n"
531 " fragmentResultReg .emit REGISTER_RESULT .or\n"
532 " fp_temporaryReg .emit REGISTER_ESTABLISHED_NAME;\n"
534 " vertexResultReg .emit REGISTER_RESULT .or\n"
535 " vp_temporaryReg .emit REGISTER_ESTABLISHED_NAME;\n"
536 "fragmentAttribReg\n"
537 " fragAttribBinding;\n"
539 " vtxAttribBinding;\n"
541 " fp_establishedName;\n"
543 " vp_establishedName;\n"
545 " fp_paramSingleItemUse .or fp_progParamReg_1;\n"
547 " vp_paramSingleItemUse .or vp_progParamReg_1;\n"
548 "fp_progParamReg_1\n"
549 " fp_progParamArray .emit PARAM_ARRAY_ELEMENT .and lbracket_ne .and progParamArrayAbs .and\n"
551 "vp_progParamReg_1\n"
552 " vp_progParamArray .emit PARAM_ARRAY_ELEMENT .and lbracket_ne .and progParamArrayMem .and\n"
554 "fp_progParamArray\n"
555 " fp_establishedName;\n"
556 "vp_progParamArray\n"
557 " vp_establishedName;\n"
558 "progParamArrayMem\n"
559 " progParamArrayAbs .or progParamArrayRel;\n"
560 "progParamArrayAbs\n"
561 " integer .emit ARRAY_INDEX_ABSOLUTE;\n"
562 "progParamArrayRel\n"
563 " addrReg .emit ARRAY_INDEX_RELATIVE .and addrComponent .and addrRegRelOffset;\n"
565 " addrRegRelOffset_1 .or addrRegRelOffset_2 .or .true .emit 0x00;\n"
566 "addrRegRelOffset_1\n"
567 " plus_ne .and addrRegPosOffset;\n"
568 "addrRegRelOffset_2\n"
569 " minus_ne .and addrRegNegOffset;\n"
574 "fragmentResultReg\n"
575 " fp_resultBinding;\n"
577 " vp_resultBinding;\n"
579 " vp_establishedName;\n"
581 " dot .and \"x\" .error INVALID_ADDRESS_COMPONENT .emit COMPONENT_X .emit COMPONENT_X\n"
582 " .emit COMPONENT_X .emit COMPONENT_X;\n"
584 " dot .and \"x\" .error INVALID_ADDRESS_WRITEMASK .emit 0x08;\n"
586 " dot .and fp_component_single .error INVALID_COMPONENT;\n"
588 " dot .and vp_component_single .error INVALID_COMPONENT;\n"
590 " swizzleSuffix_1 .or .true .emit COMPONENT_X .emit COMPONENT_Y .emit COMPONENT_Z\n"
591 " .emit COMPONENT_W;\n"
593 " dot_ne .and swizzleSuffix_2 .error INVALID_SUFFIX;\n"
595 " swizzleSuffix_3 .or swizzleSuffix_4;\n"
597 " vp_component_multi .and vp_component_multi .and vp_component_multi .error INVALID_COMPONENT .and\n"
598 " vp_component_multi .error INVALID_COMPONENT;\n"
600 " \"x\" .emit COMPONENT_X .emit COMPONENT_X .emit COMPONENT_X .emit COMPONENT_X .or\n"
601 " \"y\" .emit COMPONENT_Y .emit COMPONENT_Y .emit COMPONENT_Y .emit COMPONENT_Y .or\n"
602 " \"z\" .emit COMPONENT_Z .emit COMPONENT_Z .emit COMPONENT_Z .emit COMPONENT_Z .or\n"
603 " \"w\" .emit COMPONENT_W .emit COMPONENT_W .emit COMPONENT_W .emit COMPONENT_W;\n"
605 " optionalSuffix_1 .or .true .emit COMPONENT_X .emit COMPONENT_Y .emit COMPONENT_Z\n"
606 " .emit COMPONENT_W;\n"
608 " dot_ne .and optionalSuffix_2 .error INVALID_SUFFIX;\n"
610 " optionalSuffix_3 .or optionalSuffix_4 .or optionalSuffix_5;\n"
612 " xyzwComponent_multi .and xyzwComponent_multi .and\n"
613 " xyzwComponent_multi .error INVALID_COMPONENT .and xyzwComponent_multi .error INVALID_COMPONENT;\n"
615 " rgbaComponent_multi .and rgbaComponent_multi .and\n"
616 " rgbaComponent_multi .error INVALID_COMPONENT .and rgbaComponent_multi .error INVALID_COMPONENT;\n"
618 " \"x\" .emit COMPONENT_X .emit COMPONENT_X .emit COMPONENT_X .emit COMPONENT_X .or\n"
619 " \"y\" .emit COMPONENT_Y .emit COMPONENT_Y .emit COMPONENT_Y .emit COMPONENT_Y .or\n"
620 " \"z\" .emit COMPONENT_Z .emit COMPONENT_Z .emit COMPONENT_Z .emit COMPONENT_Z .or\n"
621 " \"w\" .emit COMPONENT_W .emit COMPONENT_W .emit COMPONENT_W .emit COMPONENT_W .or\n"
622 " \"r\" .emit COMPONENT_X .emit COMPONENT_X .emit COMPONENT_X .emit COMPONENT_X .or\n"
623 " \"g\" .emit COMPONENT_Y .emit COMPONENT_Y .emit COMPONENT_Y .emit COMPONENT_Y .or\n"
624 " \"b\" .emit COMPONENT_Z .emit COMPONENT_Z .emit COMPONENT_Z .emit COMPONENT_Z .or\n"
625 " \"a\" .emit COMPONENT_W .emit COMPONENT_W .emit COMPONENT_W .emit COMPONENT_W;\n"
626 "fp_component_single\n"
627 " xyzwComponent_single .or rgbaComponent_single;\n"
628 "vp_component_multi\n"
629 " 'x' .emit COMPONENT_X .or 'y' .emit COMPONENT_Y .or 'z' .emit COMPONENT_Z .or\n"
630 " 'w' .emit COMPONENT_W;\n"
631 "vp_component_single\n"
632 " \"x\" .emit COMPONENT_X .or \"y\" .emit COMPONENT_Y .or \"z\" .emit COMPONENT_Z .or\n"
633 " \"w\" .emit COMPONENT_W;\n"
634 "xyzwComponent_multi\n"
635 " 'x' .emit COMPONENT_X .or 'y' .emit COMPONENT_Y .or 'z' .emit COMPONENT_Z .or\n"
636 " 'w' .emit COMPONENT_W;\n"
637 "xyzwComponent_single\n"
638 " \"x\" .emit COMPONENT_X .or \"y\" .emit COMPONENT_Y .or \"z\" .emit COMPONENT_Z .or\n"
639 " \"w\" .emit COMPONENT_W;\n"
640 "rgbaComponent_multi\n"
641 " 'r' .emit COMPONENT_X .or 'g' .emit COMPONENT_Y .or 'b' .emit COMPONENT_Z .or\n"
642 " 'a' .emit COMPONENT_W;\n"
643 "rgbaComponent_single\n"
644 " \"r\" .emit COMPONENT_X .or \"g\" .emit COMPONENT_Y .or \"b\" .emit COMPONENT_Z .or\n"
645 " \"a\" .emit COMPONENT_W;\n"
647 " xyzwMask .or rgbaMask .or .true .emit 0x0F;\n"
649 " xyzwMask .or .true .emit 0x0F;\n"
651 " dot_ne .and xyzwMask_1 .error INVALID_WRITEMASK;\n"
653 " \"xyzw\" .emit 0x0F .or \"xyz\" .emit 0x0E .or \"xyw\" .emit 0x0D .or \"xy\" .emit 0x0C .or\n"
654 " \"xzw\" .emit 0x0B .or \"xz\" .emit 0x0A .or \"xw\" .emit 0x09 .or \"x\" .emit 0x08 .or\n"
655 " \"yzw\" .emit 0x07 .or \"yz\" .emit 0x06 .or \"yw\" .emit 0x05 .or \"y\" .emit 0x04 .or\n"
656 " \"zw\" .emit 0x03 .or \"z\" .emit 0x02 .or \"w\" .emit 0x01;\n"
658 " dot_ne .and rgbaMask_1 .error INVALID_WRITEMASK;\n"
660 " \"rgba\" .emit 0x0F .or \"rgb\" .emit 0x0E .or \"rga\" .emit 0x0D .or \"rg\" .emit 0x0C .or\n"
661 " \"rba\" .emit 0x0B .or \"rb\" .emit 0x0A .or \"ra\" .emit 0x09 .or \"r\" .emit 0x08 .or\n"
662 " \"gba\" .emit 0x07 .or \"gb\" .emit 0x06 .or \"ga\" .emit 0x05 .or \"g\" .emit 0x04 .or\n"
663 " \"ba\" .emit 0x03 .or \"b\" .emit 0x02 .or \"a\" .emit 0x01;\n"
664 "fp_namingStatement\n"
665 " fp_ATTRIB_statement .emit ATTRIB .or\n"
666 " fp_PARAM_statement .emit PARAM .or\n"
667 " fp_TEMP_statement .emit TEMP .or\n"
668 " fp_OUTPUT_statement .emit OUTPUT .or\n"
669 " fp_ALIAS_statement .emit ALIAS;\n"
670 "vp_namingStatement\n"
671 " vp_ATTRIB_statement .emit ATTRIB .or\n"
672 " vp_PARAM_statement .emit PARAM .or\n"
673 " vp_TEMP_statement .emit TEMP .or\n"
674 " ADDRESS_statement .emit ADDRESS .or\n"
675 " vp_OUTPUT_statement .emit OUTPUT .or\n"
676 " vp_ALIAS_statement .emit ALIAS;\n"
677 "fp_ATTRIB_statement\n"
678 " \"ATTRIB\" .and space .and fp_establishName .and equal .and\n"
679 " fragAttribBinding .error FRAGMENT_EXPECTED;\n"
680 "vp_ATTRIB_statement\n"
681 " \"ATTRIB\" .and space .and vp_establishName .and equal .and\n"
682 " vtxAttribBinding .error VERTEX_EXPECTED;\n"
683 "fragAttribBinding\n"
684 " \"fragment\" .and dot .and fragAttribItem .error INVALID_FRAGMENT_PROPERTY;\n"
686 " \"vertex\" .and dot .and vtxAttribItem .error INVALID_VERTEX_PROPERTY;\n"
688 " fragAttribItem_1 .emit FRAGMENT_ATTRIB_COLOR .or\n"
689 " fragAttribItem_2 .emit FRAGMENT_ATTRIB_TEXCOORD .or\n"
690 " \"fogcoord\" .emit FRAGMENT_ATTRIB_FOGCOORD .or\n"
691 " \"position\" .emit FRAGMENT_ATTRIB_POSITION;\n"
693 " \"color\" .and optColorType;\n"
695 " \"texcoord\" .and optTexCoordNum;\n"
697 " \"position\" .emit VERTEX_ATTRIB_POSITION .or\n"
698 " vtxAttribItem_1 .emit VERTEX_ATTRIB_WEIGHT .or\n"
699 " \"normal\" .emit VERTEX_ATTRIB_NORMAL .or\n"
700 " vtxAttribItem_2 .emit VERTEX_ATTRIB_COLOR .or\n"
701 " \"fogcoord\" .emit VERTEX_ATTRIB_FOGCOORD .or\n"
702 " vtxAttribItem_3 .emit VERTEX_ATTRIB_TEXCOORD .or\n"
703 " vtxAttribItem_4 .emit VERTEX_ATTRIB_MATRIXINDEX .or\n"
704 " vtxAttribItem_5 .emit VERTEX_ATTRIB_GENERIC;\n"
706 " \"weight\" .and vtxOptWeightNum;\n"
708 " \"color\" .and optColorType;\n"
710 " \"texcoord\" .and optTexCoordNum;\n"
712 " \"matrixindex\" .and lbracket .and vtxWeightNum .and rbracket;\n"
714 " \"attrib\" .and lbracket .and vtxAttribNum .and rbracket;\n"
718 " vtxOptWeightNum_1 .or .true .emit 0x00;\n"
719 "vtxOptWeightNum_1\n"
720 " lbracket_ne .and vtxWeightNum .and rbracket;\n"
723 "fp_PARAM_statement\n"
724 " fp_PARAM_multipleStmt .or fp_PARAM_singleStmt;\n"
725 "vp_PARAM_statement\n"
726 " vp_PARAM_multipleStmt .or vp_PARAM_singleStmt;\n"
727 "fp_PARAM_singleStmt\n"
728 " \"PARAM\" .and space .and fp_establishName .and .true .emit 0x00 .and fp_paramSingleInit .and\n"
729 " .true .emit PARAM_NULL;\n"
730 "vp_PARAM_singleStmt\n"
731 " \"PARAM\" .and space .and vp_establishName .and .true .emit 0x00 .and vp_paramSingleInit .and\n"
732 " .true .emit PARAM_NULL;\n"
733 "fp_PARAM_multipleStmt\n"
734 " \"PARAM\" .and space .and fp_establishName .and lbracket_ne .and optArraySize .and rbracket .and\n"
735 " fp_paramMultipleInit .and .true .emit PARAM_NULL;\n"
736 "vp_PARAM_multipleStmt\n"
737 " \"PARAM\" .and space .and vp_establishName .and lbracket_ne .and optArraySize .and rbracket .and\n"
738 " vp_paramMultipleInit .and .true .emit PARAM_NULL;\n"
740 " optional_integer;\n"
741 "fp_paramSingleInit\n"
742 " equal .and fp_paramSingleItemDecl;\n"
743 "vp_paramSingleInit\n"
744 " equal .and vp_paramSingleItemDecl;\n"
745 "fp_paramMultipleInit\n"
746 " equal .and lbrace .and fp_paramMultInitList .and rbrace;\n"
747 "vp_paramMultipleInit\n"
748 " equal .and lbrace .and vp_paramMultInitList .and rbrace;\n"
749 "fp_paramMultInitList\n"
750 " fp_paramMultInitList_1 .or fp_paramMultipleItem;\n"
751 "vp_paramMultInitList\n"
752 " vp_paramMultInitList_1 .or vp_paramMultipleItem;\n"
753 "fp_paramMultInitList_1\n"
754 " fp_paramMultipleItem .and comma_ne .and fp_paramMultInitList;\n"
755 "vp_paramMultInitList_1\n"
756 " vp_paramMultipleItem .and comma_ne .and vp_paramMultInitList;\n"
757 "fp_paramSingleItemDecl\n"
758 " fp_stateSingleItem .emit PARAM_STATE_ELEMENT .or\n"
759 " programSingleItem .emit PARAM_PROGRAM_ELEMENT .or\n"
760 " paramConstDecl .emit PARAM_CONSTANT;\n"
761 "vp_paramSingleItemDecl\n"
762 " vp_stateSingleItem .emit PARAM_STATE_ELEMENT .or\n"
763 " programSingleItem .emit PARAM_PROGRAM_ELEMENT .or\n"
764 " paramConstDecl .emit PARAM_CONSTANT;\n"
765 "fp_paramSingleItemUse\n"
766 " fp_stateSingleItem .emit PARAM_STATE_ELEMENT .or\n"
767 " programSingleItem .emit PARAM_PROGRAM_ELEMENT .or\n"
768 " paramConstUse .emit PARAM_CONSTANT;\n"
769 "vp_paramSingleItemUse\n"
770 " vp_stateSingleItem .emit PARAM_STATE_ELEMENT .or\n"
771 " programSingleItem .emit PARAM_PROGRAM_ELEMENT .or\n"
772 " paramConstUse .emit PARAM_CONSTANT;\n"
773 "fp_paramMultipleItem\n"
774 " fp_stateMultipleItem .emit PARAM_STATE_ELEMENT .or\n"
775 " programMultipleItem .emit PARAM_PROGRAM_ELEMENT .or\n"
776 " paramConstDecl .emit PARAM_CONSTANT;\n"
777 "vp_paramMultipleItem\n"
778 " vp_stateMultipleItem .emit PARAM_STATE_ELEMENT .or\n"
779 " programMultipleItem .emit PARAM_PROGRAM_ELEMENT .or\n"
780 " paramConstDecl .emit PARAM_CONSTANT;\n"
781 "fp_stateMultipleItem\n"
782 " stateMultipleItem_1 .or fp_stateSingleItem;\n"
783 "vp_stateMultipleItem\n"
784 " stateMultipleItem_1 .or vp_stateSingleItem;\n"
785 "stateMultipleItem_1\n"
786 " \"state\" .and dot .and stateMatrixRows .emit STATE_MATRIX_ROWS;\n"
787 "fp_stateSingleItem\n"
788 " \"state\" .and dot .and fp_stateSingleItem_1 .error INVALID_STATE_PROPERTY;\n"
789 "vp_stateSingleItem\n"
790 " \"state\" .and dot .and vp_stateSingleItem_1 .error INVALID_STATE_PROPERTY;\n"
791 "fp_stateSingleItem_1\n"
792 " stateSingleItem_1 .or stateSingleItem_2 .or stateSingleItem_3 .or stateSingleItem_4 .or\n"
793 " stateSingleItem_5 .or stateSingleItem_7 .or stateSingleItem_8 .or stateSingleItem_11;\n"
794 "vp_stateSingleItem_1\n"
795 " stateSingleItem_1 .or stateSingleItem_2 .or stateSingleItem_3 .or stateSingleItem_4 .or\n"
796 " stateSingleItem_6 .or stateSingleItem_7 .or stateSingleItem_9 .or stateSingleItem_10 .or\n"
797 " stateSingleItem_11;\n"
798 "stateSingleItem_1\n"
799 " stateMaterialItem .emit STATE_MATERIAL;\n"
800 "stateSingleItem_2\n"
801 " stateLightItem .emit STATE_LIGHT;\n"
802 "stateSingleItem_3\n"
803 " stateLightModelItem .emit STATE_LIGHT_MODEL;\n"
804 "stateSingleItem_4\n"
805 " stateLightProdItem .emit STATE_LIGHT_PROD;\n"
806 "stateSingleItem_5\n"
807 " stateTexEnvItem .emit STATE_TEX_ENV;\n"
808 "stateSingleItem_6\n"
809 " stateTexGenItem .emit STATE_TEX_GEN;\n"
810 "stateSingleItem_7\n"
811 " stateFogItem .emit STATE_FOG;\n"
812 "stateSingleItem_8\n"
813 " stateDepthItem .emit STATE_DEPTH;\n"
814 "stateSingleItem_9\n"
815 " stateClipPlaneItem .emit STATE_CLIP_PLANE;\n"
816 "stateSingleItem_10\n"
817 " statePointItem .emit STATE_POINT;\n"
818 "stateSingleItem_11\n"
819 " stateMatrixRow .emit STATE_MATRIX_ROWS;\n"
820 "stateMaterialItem\n"
821 " \"material\" .and optFaceType .and dot .and stateMatProperty .error INVALID_MATERIAL_PROPERTY;\n"
823 " \"ambient\" .emit MATERIAL_AMBIENT .or\n"
824 " \"diffuse\" .emit MATERIAL_DIFFUSE .or\n"
825 " \"specular\" .emit MATERIAL_SPECULAR .or\n"
826 " \"emission\" .emit MATERIAL_EMISSION .or\n"
827 " \"shininess\" .emit MATERIAL_SHININESS;\n"
829 " \"light\" .and lbracket .and stateLightNumber .and rbracket .and dot .and\n"
830 " stateLightProperty .error INVALID_LIGHT_PROPERTY;\n"
831 "stateLightProperty\n"
832 " \"ambient\" .emit LIGHT_AMBIENT .or\n"
833 " \"diffuse\" .emit LIGHT_DIFFUSE .or\n"
834 " \"specular\" .emit LIGHT_SPECULAR .or\n"
835 " \"position\" .emit LIGHT_POSITION .or\n"
836 " \"attenuation\" .emit LIGHT_ATTENUATION .or\n"
837 " stateLightProperty_1 .emit LIGHT_SPOT_DIRECTION .or\n"
838 " \"half\" .emit LIGHT_HALF;\n"
839 "stateLightProperty_1\n"
840 " \"spot\" .and dot .and stateSpotProperty .error INVALID_SPOT_PROPERTY;\n"
841 "stateSpotProperty\n"
843 "stateLightModelItem\n"
844 " \"lightmodel\" .and stateLModProperty .error INVALID_LIGHTMODEL_PROPERTY;\n"
845 "stateLModProperty\n"
846 " stateLModProperty_1 .or stateLModProperty_2;\n"
847 "stateLModProperty_1\n"
848 " dot .and \"ambient\" .emit LIGHT_MODEL_AMBIENT;\n"
849 "stateLModProperty_2\n"
850 " optFaceType .and dot .and \"scenecolor\" .emit LIGHT_MODEL_SCENECOLOR;\n"
851 "stateLightProdItem\n"
852 " \"lightprod\" .and lbracket .and stateLightNumber .and rbracket .and optFaceType .and dot .and\n"
853 " stateLProdProperty .error INVALID_LIGHTPROD_PROPERTY;\n"
854 "stateLProdProperty\n"
855 " \"ambient\" .emit LIGHT_PROD_AMBIENT .or\n"
856 " \"diffuse\" .emit LIGHT_PROD_DIFFUSE .or\n"
857 " \"specular\" .emit LIGHT_PROD_SPECULAR;\n"
861 " \"texenv\" .and optLegacyTexUnitNum .and dot .and\n"
862 " stateTexEnvProperty .error INVALID_TEXENV_PROPERTY;\n"
863 "stateTexEnvProperty\n"
864 " \"color\" .emit TEX_ENV_COLOR;\n"
865 "optLegacyTexUnitNum\n"
866 " lbracket_ne .and legacyTexUnitNum .and rbracket;\n"
870 " \"texgen\" .and optTexCoordNum .and dot .and stateTexGenType .error INVALID_TEXGEN_PROPERTY .and\n"
871 " dot .and stateTexGenCoord .error INVALID_TEXGEN_COORD;\n"
873 " \"eye\" .emit TEX_GEN_EYE .or\n"
874 " \"object\" .emit TEX_GEN_OBJECT;\n"
876 " \"s\" .emit COMPONENT_X .or\n"
877 " \"t\" .emit COMPONENT_Y .or\n"
878 " \"r\" .emit COMPONENT_Z .or\n"
879 " \"q\" .emit COMPONENT_W;\n"
881 " \"fog\" .and dot .and stateFogProperty .error INVALID_FOG_PROPERTY;\n"
883 " \"color\" .emit FOG_COLOR .or\n"
884 " \"params\" .emit FOG_PARAMS;\n"
886 " \"depth\" .and dot .and stateDepthProperty .error INVALID_DEPTH_PROPERTY;\n"
887 "stateDepthProperty\n"
888 " \"range\" .emit DEPTH_RANGE;\n"
889 "stateClipPlaneItem\n"
890 " \"clip\" .and lbracket .and stateClipPlaneNum .and rbracket .and dot .and\n"
891 " \"plane\" .error INVALID_CLIPPLANE_PROPERTY;\n"
892 "stateClipPlaneNum\n"
895 " \"point\" .and dot .and statePointProperty .error INVALID_POINT_PROPERTY;\n"
896 "statePointProperty\n"
897 " \"size\" .emit POINT_SIZE .or\n"
898 " \"attenuation\" .emit POINT_ATTENUATION;\n"
900 " stateMatrixItem .and dot .and \"row\" .error MATRIX_ROW_SELECTOR_OR_MODIFIER_EXPECTED .and\n"
901 " lbracket .and stateMatrixRowNum .and rbracket .emit 0x0;\n"
903 " stateMatrixItem .and optMatrixRows;\n"
905 " optMatrixRows_1 .or .true .emit 0x0 .emit '3' .emit 0x0 .emit $;\n"
907 " dot_ne .and \"row\" .error MATRIX_ROW_SELECTOR_OR_MODIFIER_EXPECTED .and lbracket .and\n"
908 " stateMatrixRowNum .and dotdot .and stateMatrixRowNum .and rbracket;\n"
910 " \"matrix\" .and dot .and stateMatrixName .error INVALID_MATRIX_NAME .and stateOptMatModifier;\n"
911 "stateOptMatModifier\n"
912 " stateOptMatModifier_1 .or .true .emit MATRIX_MODIFIER_IDENTITY;\n"
913 "stateOptMatModifier_1\n"
914 " dot_ne .and stateMatModifier;\n"
916 " \"inverse\" .emit MATRIX_MODIFIER_INVERSE .or\n"
917 " \"transpose\" .emit MATRIX_MODIFIER_TRANSPOSE .or\n"
918 " \"invtrans\" .emit MATRIX_MODIFIER_INVTRANS;\n"
919 "stateMatrixRowNum\n"
922 " stateMatrixName_1_1 .emit MATRIX_MODELVIEW .or\n"
923 " \"projection\" .emit MATRIX_PROJECTION .or\n"
924 " \"mvp\" .emit MATRIX_MVP .or\n"
925 " stateMatrixName_1_2 .emit MATRIX_TEXTURE .or\n"
926 " stateMatrixName_1_3 .emit MATRIX_PALETTE .or\n"
927 " stateMatrixName_1_4 .emit MATRIX_PROGRAM;\n"
928 "stateMatrixName_1_1\n"
929 " \"modelview\" .and stateOptModMatNum;\n"
930 "stateMatrixName_1_2\n"
931 " \"texture\" .and optTexCoordNum;\n"
932 "stateMatrixName_1_3\n"
933 " \"palette\" .and lbracket .and statePaletteMatNum .and rbracket;\n"
934 "stateMatrixName_1_4\n"
935 " \"program\" .and lbracket .and stateProgramMatNum .and rbracket;\n"
936 "stateOptModMatNum\n"
937 " stateOptModMatNum_1 .or .true .emit 0x00;\n"
938 "stateOptModMatNum_1\n"
939 " lbracket_ne .and stateModMatNum .and rbracket;\n"
943 " optTexCoordNum_1 .or .true .emit 0x00;\n"
945 " lbracket_ne .and texCoordNum .and rbracket;\n"
948 "statePaletteMatNum\n"
950 "stateProgramMatNum\n"
952 "programSingleItem\n"
953 " \"program\" .and dot .and programSingleItem_1 .error INVALID_PROGRAM_PROPERTY;\n"
954 "programSingleItem_1\n"
955 " progEnvParam .or progLocalParam;\n"
956 "programMultipleItem\n"
957 " \"program\" .and dot .and programMultipleItem_1 .error INVALID_PROGRAM_PROPERTY;\n"
958 "programMultipleItem_1\n"
959 " progEnvParams .or progLocalParams;\n"
961 " \"env\" .emit PROGRAM_PARAM_ENV .and lbracket .and progEnvParamNums .and rbracket;\n"
963 " progEnvParamNums_1 .or progEnvParamNums_2;\n"
964 "progEnvParamNums_1\n"
965 " progEnvParamNum .and dotdot_ne .and progEnvParamNum;\n"
966 "progEnvParamNums_2\n"
967 " progEnvParamNum .and .true .emit 0x00;\n"
969 " \"env\" .emit PROGRAM_PARAM_ENV .and lbracket .and progEnvParamNum .and rbracket .emit 0x00;\n"
971 " \"local\" .emit PROGRAM_PARAM_LOCAL .and lbracket .and progLocalParamNums .and rbracket;\n"
972 "progLocalParamNums\n"
973 " progLocalParamNums_1 .or progLocalParamNums_2;\n"
974 "progLocalParamNums_1\n"
975 " progLocalParamNum .and dotdot_ne .and progLocalParamNum;\n"
976 "progLocalParamNums_2\n"
977 " progLocalParamNum .and .true .emit 0x00;\n"
979 " \"local\" .emit PROGRAM_PARAM_LOCAL .and lbracket .and progLocalParamNum .and rbracket .emit 0x00;\n"
982 "progLocalParamNum\n"
985 " paramConstScalarDecl .emit CONSTANT_SCALAR .or paramConstVector .emit CONSTANT_VECTOR;\n"
987 " paramConstScalarUse .emit CONSTANT_SCALAR .or paramConstVector .emit CONSTANT_VECTOR;\n"
988 "paramConstScalarDecl\n"
989 " signedFloatConstant;\n"
990 "paramConstScalarUse\n"
993 " paramConstVector_4 .emit 0x04 .or paramConstVector_3 .emit 0x03 .or\n"
994 " paramConstVector_2 .emit 0x02 .or paramConstVector_1 .emit 0x01;\n"
995 "paramConstVector_1\n"
996 " lbrace_ne .and signedFloatConstant .and rbrace;\n"
997 "paramConstVector_2\n"
998 " lbrace_ne .and signedFloatConstant .and comma_ne .and signedFloatConstant .and rbrace;\n"
999 "paramConstVector_3\n"
1000 " lbrace_ne .and signedFloatConstant .and comma_ne .and signedFloatConstant .and comma_ne .and\n"
1001 " signedFloatConstant .and rbrace;\n"
1002 "paramConstVector_4\n"
1003 " lbrace_ne .and signedFloatConstant .and comma_ne .and signedFloatConstant .and comma_ne .and\n"
1004 " signedFloatConstant .and comma_ne .and signedFloatConstant .and rbrace;\n"
1005 "signedFloatConstant\n"
1006 " optionalSign .and floatConstant;\n"
1010 " optional_sign_ne;\n"
1011 "fp_TEMP_statement\n"
1012 " \"TEMP\" .and space .and fp_varNameList .and .true .emit 0x00;\n"
1013 "vp_TEMP_statement\n"
1014 " \"TEMP\" .and space .and vp_varNameList .and .true .emit 0x00;\n"
1015 "ADDRESS_statement\n"
1016 " \"ADDRESS\" .and space .and vp_varNameList .and .true .emit 0x00;\n"
1018 " fp_varNameList_1 .or fp_establishName;\n"
1020 " vp_varNameList_1 .or vp_establishName;\n"
1021 "fp_varNameList_1\n"
1022 " fp_establishName .and comma_ne .and fp_varNameList;\n"
1023 "vp_varNameList_1\n"
1024 " vp_establishName .and comma_ne .and vp_varNameList;\n"
1025 "fp_OUTPUT_statement\n"
1026 " \"OUTPUT\" .and space .and fp_establishName .and equal .and\n"
1027 " fp_resultBinding .error RESULT_EXPECTED;\n"
1028 "vp_OUTPUT_statement\n"
1029 " \"OUTPUT\" .and space .and vp_establishName .and equal .and\n"
1030 " vp_resultBinding .error RESULT_EXPECTED;\n"
1031 "fp_resultBinding\n"
1032 " \"result\" .and dot .and fp_resultBinding_1 .error INVALID_RESULT_PROPERTY;\n"
1033 "vp_resultBinding\n"
1034 " \"result\" .and dot .and vp_resultBinding_1 .error INVALID_RESULT_PROPERTY;\n"
1035 "fp_resultBinding_1\n"
1036 " \"color\" .emit FRAGMENT_RESULT_COLOR .or\n"
1037 " \"depth\" .emit FRAGMENT_RESULT_DEPTH;\n"
1038 "vp_resultBinding_1\n"
1039 " \"position\" .emit VERTEX_RESULT_POSITION .or\n"
1040 " resultColBinding .emit VERTEX_RESULT_COLOR .or\n"
1041 " \"fogcoord\" .emit VERTEX_RESULT_FOGCOORD .or\n"
1042 " \"pointsize\" .emit VERTEX_RESULT_POINTSIZE .or\n"
1043 " vp_resultBinding_2 .emit VERTEX_RESULT_TEXCOORD;\n"
1044 "vp_resultBinding_2\n"
1045 " \"texcoord\" .and optTexCoordNum;\n"
1046 "resultColBinding\n"
1047 " \"color\" .and optFaceType .and optColorType;\n"
1049 " FaceType .or .true .emit FACE_FRONT;\n"
1051 " dot_ne .and FaceProperty;\n"
1053 " \"front\" .emit FACE_FRONT .or \"back\" .emit FACE_BACK;\n"
1055 " ColorType .or .true .emit COLOR_PRIMARY;\n"
1057 " dot_ne .and ColorProperty .error INVALID_COLOR_PROPERTY;\n"
1059 " \"primary\" .emit COLOR_PRIMARY .or \"secondary\" .emit COLOR_SECONDARY;\n"
1060 "fp_ALIAS_statement\n"
1061 " \"ALIAS\" .and space .and fp_establishName .and equal .and fp_establishedName;\n"
1062 "vp_ALIAS_statement\n"
1063 " \"ALIAS\" .and space .and vp_establishName .and equal .and vp_establishedName;\n"
1064 "fp_establishName\n"
1066 "vp_establishName\n"
1068 "fp_establishedName\n"
1070 "vp_establishedName\n"
1073 " fp_not_reserved_identifier .and identifier_ne .error IDENTIFIER_EXPECTED;\n"
1075 " vp_not_reserved_identifier .and identifier_ne .error IDENTIFIER_EXPECTED;\n"
1076 "fp_not_reserved_identifier\n"
1077 " fp_not_reserved_identifier_1 .or .true;\n"
1078 "fp_not_reserved_identifier_1\n"
1079 " fp_reserved_identifier .and .false .error RESERVED_KEYWORD;\n"
1080 "vp_not_reserved_identifier\n"
1081 " vp_not_reserved_identifier_1 .or .true;\n"
1082 "vp_not_reserved_identifier_1\n"
1083 " vp_reserved_identifier .and .false .error RESERVED_KEYWORD;\n"
1084 "fp_reserved_identifier\n"
1085 " \"ABS\" .or \"ABS_SAT\" .or \"ADD\" .or \"ADD_SAT\" .or \"ALIAS\" .or \"ATTRIB\" .or \"CMP\" .or \"CMP_SAT\" .or\n"
1086 " \"COS\" .or \"COS_SAT\" .or \"DP3\" .or \"DP3_SAT\" .or \"DP4\" .or \"DP4_SAT\" .or \"DPH\" .or \"DPH_SAT\" .or\n"
1087 " \"DST\" .or \"DST_SAT\" .or \"END\" .or \"EX2\" .or \"EX2_SAT\" .or \"FLR\" .or \"FLR_SAT\" .or \"FRC\" .or\n"
1088 " \"FRC_SAT\" .or \"KIL\" .or \"LG2\" .or \"LG2_SAT\" .or \"LIT\" .or \"LIT_SAT\" .or \"LRP\" .or \"LRP_SAT\" .or\n"
1089 " \"MAD\" .or \"MAD_SAT\" .or \"MAX\" .or \"MAX_SAT\" .or \"MIN\" .or \"MIN_SAT\" .or \"MOV\" .or \"MOV_SAT\" .or\n"
1090 " \"MUL\" .or \"MUL_SAT\" .or \"OPTION\" .or \"OUTPUT\" .or \"PARAM\" .or \"POW\" .or \"POW_SAT\" .or \"RCP\" .or\n"
1091 " \"RCP_SAT\" .or \"RSQ\" .or \"RSQ_SAT\" .or \"SIN\" .or \"SIN_SAT\" .or \"SCS\" .or \"SCS_SAT\" .or \"SGE\" .or\n"
1092 " \"SGE_SAT\" .or \"SLT\" .or \"SLT_SAT\" .or \"SUB\" .or \"SUB_SAT\" .or \"SWZ\" .or \"SWZ_SAT\" .or \"TEMP\" .or\n"
1093 " \"TEX\" .or \"TEX_SAT\" .or \"TXB\" .or \"TXB_SAT\" .or \"TXP\" .or \"TXP_SAT\" .or \"XPD\" .or \"XPD_SAT\" .or\n"
1094 " \"fragment\" .or \"program\" .or \"result\" .or \"state\" .or \"texture\";\n"
1095 "vp_reserved_identifier\n"
1096 " \"ABS\" .or \"ADD\" .or \"ADDRESS\" .or \"ALIAS\" .or \"ARL\" .or \"ATTRIB\" .or \"DP3\" .or \"DP4\" .or\n"
1097 " \"DPH\" .or \"DST\" .or \"END\" .or \"EX2\" .or \"EXP\" .or \"FLR\" .or \"FRC\" .or \"LG2\" .or \"LIT\" .or\n"
1098 " \"LOG\" .or \"MAD\" .or \"MAX\" .or \"MIN\" .or \"MOV\" .or \"MUL\" .or \"OPTION\" .or \"OUTPUT\" .or\n"
1099 " \"PARAM\" .or \"POW\" .or \"RCP\" .or \"RSQ\" .or \"SGE\" .or \"SLT\" .or \"SUB\" .or \"SWZ\" .or \"TEMP\" .or\n"
1100 " \"XPD\" .or \"program\" .or \"result\" .or \"state\" .or \"vertex\";\n"
1102 " integer_ne .error INTEGER_EXPECTED;\n"
1110 " space .or .true;\n"
1112 " single_space .and .loop single_space;\n"
1114 " white_char .or comment_block;\n"
1116 " ' ' .or '\\t' .or '\\n' .or '\\r';\n"
1118 " '#' .and .loop comment_char .and new_line;\n"
1120 " '\\x0E'-'\\xFF' .or '\\x01'-'\\x09' .or '\\x0B'-'\\x0C';\n"
1122 " '\\n' .or crlf .or '\\0';\n"
1124 " '\\r' .and '\\n';\n"
1126 " optional_space .and ';' .error MISSING_SEMICOLON .and optional_space;\n"
1128 " optional_space .and ',' .error MISSING_COMMA .and optional_space;\n"
1130 " optional_space .and ',' .and optional_space;\n"
1132 " optional_space .and '[' .error MISSING_LBRACKET .and optional_space;\n"
1134 " optional_space .and '[' .and optional_space;\n"
1136 " optional_space .and ']' .error MISSING_RBRACKET .and optional_space;\n"
1138 " optional_space .and '.' .error MISSING_DOT .and optional_space;\n"
1140 " optional_space .and '.' .and optional_space;\n"
1142 " optional_space .and '=' .error MISSING_EQUAL .and optional_space;\n"
1144 " optional_space .and '{' .error MISSING_LBRACE .and optional_space;\n"
1146 " optional_space .and '{' .and optional_space;\n"
1148 " optional_space .and '}' .error MISSING_RBRACE .and optional_space;\n"
1150 " optional_space .and '.' .and '.' .error MISSING_DOTDOT .and optional_space;\n"
1152 " optional_space .and '.' .and '.' .and optional_space;\n"
1154 " float_1 .or float_2;\n"
1156 " '.' .emit 0x00 .and integer_ne .error MISSING_FRACTION_OR_EXPONENT .and optional_exponent;\n"
1158 " integer_ne .and float_3 .error MISSING_DOT_OR_EXPONENT;\n"
1160 " float_4 .or float_5;\n"
1162 " '.' .and optional_integer .and optional_exponent;\n"
1164 " exponent .emit 0x00;\n"
1166 " integer_ne_1 .and .true .emit 0x00 .emit $;\n"
1168 " digit10 .emit * .and .loop digit10 .emit *;\n"
1169 "optional_integer\n"
1170 " integer_ne .or .true .emit 0x00;\n"
1171 "optional_exponent\n"
1172 " exponent .or .true .emit '1' .emit 0x00 .emit $;\n"
1174 " exponent_1 .and optional_sign_ne .and integer_ne .error EXPONENT_VALUE_EXPECTED;\n"
1177 "optional_sign_ne\n"
1178 " minus_ne .or plus_ne .or .true;\n"
1180 " optional_space .and '+' .and optional_space;\n"
1182 " optional_space .and '-' .emit '-' .and optional_space;\n"
1184 " first_idchar .emit * .and .loop follow_idchar .emit * .and .true .emit 0x00 .emit $;\n"
1186 " first_idchar .or digit10;\n"
1188 " 'a'-'z' .or 'A'-'Z' .or '_' .or '$';\n"
1191 ".string __string_filter;\n"
1193 " .loop __identifier_char;\n"
1194 "__identifier_char\n"
1195 " 'a'-'z' .or 'A'-'Z' .or '_' .or '$' .or '0'-'9';\n"
1197 " e_signature_char .and .loop e_signature_char;\n"
1198 "e_signature_char\n"
1199 " '!' .or '.' .or 'A'-'Z' .or 'a'-'z' .or '0'-'9';\n"
1201 " .loop e_statement_not_term;\n"
1202 "e_statement_not_term\n"
1203 " '\\x3C'-'\\xFF' .or '\\x0E'-'\\x3A' .or '\\x01'-'\\x09' .or '\\x0B'-'\\x0C';\n"
1205 " e_identifier_first .and .loop e_identifier_next;\n"
1206 "e_identifier_first\n"
1207 " 'a'-'z' .or 'A'-'Z' .or '_' .or '$';\n"
1208 "e_identifier_next\n"
1209 " e_identifier_first .or '0'-'9';\n"
1211 " e_identifier .or e_token_number .or '[' .or ']' .or '.' .or '{' .or '}' .or '=' .or '+' .or\n"
1212 " '-' .or ',' .or ';';\n"
1214 " e_token_digit .and .loop e_token_digit;\n"
1218 " 'A'-'Z' .or 'a'-'z' .or '0'-'9';\n"