1 /* A Bison parser, made by GNU Bison 1.875.  */
2 
3 /* Skeleton parser for Yacc-like parsing with Bison,
4    Copyright (C) 1984, 1989, 1990, 2000, 2001, 2002 Free Software Foundation, Inc.
5 
6    This program is free software; you can redistribute it and/or modify
7    it under the terms of the GNU General Public License as published by
8    the Free Software Foundation; either version 2, or (at your option)
9    any later version.
10 
11    This program is distributed in the hope that it will be useful,
12    but WITHOUT ANY WARRANTY; without even the implied warranty of
13    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
14    GNU General Public License for more details.
15 
16    You should have received a copy of the GNU General Public License
17    along with this program; if not, write to the Free Software
18    Foundation, Inc., 59 Temple Place - Suite 330,
19    Boston, MA 02111-1307, USA.  */
20 
21 /* As a special exception, when this file is copied by Bison into a
22    Bison output file, you may use that output file without restriction.
23    This special exception was added by the Free Software Foundation
24    in version 1.24 of Bison.  */
25 
26 /* Written by Richard Stallman by simplifying the original so called
27    ``semantic'' parser.  */
28 
29 /* All symbols defined below should begin with yy or YY, to avoid
30    infringing on user name space.  This should be done even for local
31    variables, as they might otherwise be expanded by user macros.
32    There are some unavoidable exceptions within include files to
33    define necessary library symbols; they are noted "INFRINGES ON
34    USER NAME SPACE" below.  */
35 
36 /* Identify Bison output.  */
37 #define YYBISON 1
38 
39 /* Skeleton name.  */
40 #define YYSKELETON_NAME "yacc.c"
41 
42 /* Pure parsers.  */
43 #define YYPURE 1
44 
45 /* Using locations.  */
46 #define YYLSP_NEEDED 0
47 
48 
49 
50 /* Tokens.  */
51 #ifndef YYTOKENTYPE
52 # define YYTOKENTYPE
53    /* Put the tokens into the symbol table, so that GDB and other debuggers
54       know about them.  */
55    enum yytokentype {
56      TOK_CONST_INT = 258,
57      TOK_CONST_FLOAT = 259,
58      TOK_CONST_STRING = 260,
59      TOK_ATTR_INT = 261,
60      TOK_ATTR_BITS = 262,
61      TOK_ATTR_FLOAT = 263,
62      TOK_ATTR_MVA32 = 264,
63      TOK_ATTR_MVA64 = 265,
64      TOK_ATTR_STRING = 266,
65      TOK_FUNC = 267,
66      TOK_FUNC_IN = 268,
67      TOK_USERVAR = 269,
68      TOK_UDF = 270,
69      TOK_HOOK_IDENT = 271,
70      TOK_HOOK_FUNC = 272,
71      TOK_ATID = 273,
72      TOK_ATWEIGHT = 274,
73      TOK_ID = 275,
74      TOK_WEIGHT = 276,
75      TOK_COUNT = 277,
76      TOK_DISTINCT = 278,
77      TOK_CONST_LIST = 279,
78      TOK_ATTR_SINT = 280,
79      TOK_OR = 281,
80      TOK_AND = 282,
81      TOK_NE = 283,
82      TOK_EQ = 284,
83      TOK_GTE = 285,
84      TOK_LTE = 286,
85      TOK_MOD = 287,
86      TOK_DIV = 288,
87      TOK_NOT = 289,
88      TOK_NEG = 290
89    };
90 #endif
91 #define TOK_CONST_INT 258
92 #define TOK_CONST_FLOAT 259
93 #define TOK_CONST_STRING 260
94 #define TOK_ATTR_INT 261
95 #define TOK_ATTR_BITS 262
96 #define TOK_ATTR_FLOAT 263
97 #define TOK_ATTR_MVA32 264
98 #define TOK_ATTR_MVA64 265
99 #define TOK_ATTR_STRING 266
100 #define TOK_FUNC 267
101 #define TOK_FUNC_IN 268
102 #define TOK_USERVAR 269
103 #define TOK_UDF 270
104 #define TOK_HOOK_IDENT 271
105 #define TOK_HOOK_FUNC 272
106 #define TOK_ATID 273
107 #define TOK_ATWEIGHT 274
108 #define TOK_ID 275
109 #define TOK_WEIGHT 276
110 #define TOK_COUNT 277
111 #define TOK_DISTINCT 278
112 #define TOK_CONST_LIST 279
113 #define TOK_ATTR_SINT 280
114 #define TOK_OR 281
115 #define TOK_AND 282
116 #define TOK_NE 283
117 #define TOK_EQ 284
118 #define TOK_GTE 285
119 #define TOK_LTE 286
120 #define TOK_MOD 287
121 #define TOK_DIV 288
122 #define TOK_NOT 289
123 #define TOK_NEG 290
124 
125 
126 
127 
128 /* Copy the first part of user declarations.  */
129 
130 
131 /* Enabling traces.  */
132 #ifndef YYDEBUG
133 # define YYDEBUG 0
134 #endif
135 
136 /* Enabling verbose error messages.  */
137 #ifdef YYERROR_VERBOSE
138 # undef YYERROR_VERBOSE
139 # define YYERROR_VERBOSE 1
140 #else
141 # define YYERROR_VERBOSE 1
142 #endif
143 
144 #if ! defined (YYSTYPE) && ! defined (YYSTYPE_IS_DECLARED)
145 
146 typedef union YYSTYPE {
147 	int64_t			iConst;			// constant value
148 	float			fConst;			// constant value
149 	uint64_t		iAttrLocator;	// attribute locator (rowitem for int/float; offset+size for bits)
150 	int				iFunc;			// function id
151 	int				iNode;			// node, or uservar, or udf index
152 } YYSTYPE;
153 /* Line 186 of yacc.c.  */
154 
155 # define yystype YYSTYPE /* obsolescent; will be withdrawn */
156 # define YYSTYPE_IS_DECLARED 1
157 # define YYSTYPE_IS_TRIVIAL 1
158 #endif
159 
160 
161 
162 /* Copy the second part of user declarations.  */
163 
164 
165 /* Line 214 of yacc.c.  */
166 
167 
168 #if ! defined (yyoverflow) || YYERROR_VERBOSE
169 
170 /* The parser invokes alloca or malloc; define the necessary symbols.  */
171 
172 # if YYSTACK_USE_ALLOCA
173 #  define YYSTACK_ALLOC alloca
174 # else
175 #  ifndef YYSTACK_USE_ALLOCA
176 #   if defined (alloca) || defined (_ALLOCA_H)
177 #    define YYSTACK_ALLOC alloca
178 #   else
179 #    ifdef __GNUC__
180 #     define YYSTACK_ALLOC __builtin_alloca
181 #    endif
182 #   endif
183 #  endif
184 # endif
185 
186 # ifdef YYSTACK_ALLOC
187    /* Pacify GCC's `empty if-body' warning. */
188 #  define YYSTACK_FREE(Ptr) do { /* empty */; } while (0)
189 # else
190 #  if defined (__STDC__) || defined (__cplusplus)
191 #   include <stdlib.h> /* INFRINGES ON USER NAME SPACE */
192 #   define YYSIZE_T size_t
193 #  endif
194 #  define YYSTACK_ALLOC malloc
195 #  define YYSTACK_FREE free
196 # endif
197 #endif /* ! defined (yyoverflow) || YYERROR_VERBOSE */
198 
199 
200 #if (! defined (yyoverflow) \
201      && (! defined (__cplusplus) \
202 	 || (YYSTYPE_IS_TRIVIAL)))
203 
204 /* A type that is properly aligned for any stack member.  */
205 union yyalloc
206 {
207   short yyss;
208   YYSTYPE yyvs;
209   };
210 
211 /* The size of the maximum gap between one aligned stack and the next.  */
212 # define YYSTACK_GAP_MAXIMUM (sizeof (union yyalloc) - 1)
213 
214 /* The size of an array large to enough to hold all stacks, each with
215    N elements.  */
216 # define YYSTACK_BYTES(N) \
217      ((N) * (sizeof (short) + sizeof (YYSTYPE))				\
218       + YYSTACK_GAP_MAXIMUM)
219 
220 /* Copy COUNT objects from FROM to TO.  The source and destination do
221    not overlap.  */
222 # ifndef YYCOPY
223 #  if 1 < __GNUC__
224 #   define YYCOPY(To, From, Count) \
225       __builtin_memcpy (To, From, (Count) * sizeof (*(From)))
226 #  else
227 #   define YYCOPY(To, From, Count)		\
228       do					\
229 	{					\
230 	  register YYSIZE_T yyi;		\
231 	  for (yyi = 0; yyi < (Count); yyi++)	\
232 	    (To)[yyi] = (From)[yyi];		\
233 	}					\
234       while (0)
235 #  endif
236 # endif
237 
238 /* Relocate STACK from its old location to the new one.  The
239    local variables YYSIZE and YYSTACKSIZE give the old and new number of
240    elements in the stack, and YYPTR gives the new location of the
241    stack.  Advance YYPTR to a properly aligned location for the next
242    stack.  */
243 # define YYSTACK_RELOCATE(Stack)					\
244     do									\
245       {									\
246 	YYSIZE_T yynewbytes;						\
247 	YYCOPY (&yyptr->Stack, Stack, yysize);				\
248 	Stack = &yyptr->Stack;						\
249 	yynewbytes = yystacksize * sizeof (*Stack) + YYSTACK_GAP_MAXIMUM; \
250 	yyptr += yynewbytes / sizeof (*yyptr);				\
251       }									\
252     while (0)
253 
254 #endif
255 
256 #if defined (__STDC__) || defined (__cplusplus)
257    typedef signed char yysigned_char;
258 #else
259    typedef short yysigned_char;
260 #endif
261 
262 /* YYFINAL -- State number of the termination state. */
263 #define YYFINAL  30
264 /* YYLAST -- Last index in YYTABLE.  */
265 #define YYLAST   285
266 
267 /* YYNTOKENS -- Number of terminals. */
268 #define YYNTOKENS  48
269 /* YYNNTS -- Number of nonterminals. */
270 #define YYNNTS  9
271 /* YYNRULES -- Number of rules. */
272 #define YYNRULES  57
273 /* YYNRULES -- Number of states. */
274 #define YYNSTATES  100
275 
276 /* YYTRANSLATE(YYLEX) -- Bison symbol number corresponding to YYLEX.  */
277 #define YYUNDEFTOK  2
278 #define YYMAXUTOK   290
279 
280 #define YYTRANSLATE(YYX) 						\
281   ((unsigned int) (YYX) <= YYMAXUTOK ? yytranslate[YYX] : YYUNDEFTOK)
282 
283 /* YYTRANSLATE[YYLEX] -- Bison symbol number corresponding to YYLEX.  */
284 static const unsigned char yytranslate[] =
285 {
286        0,     2,     2,     2,     2,     2,     2,     2,     2,     2,
287        2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
288        2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
289        2,     2,     2,     2,     2,     2,     2,    40,    29,     2,
290       45,    46,    38,    36,    47,    37,     2,    39,     2,     2,
291        2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
292       32,     2,    33,     2,     2,     2,     2,     2,     2,     2,
293        2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
294        2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
295        2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
296        2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
297        2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
298        2,     2,     2,     2,    28,     2,     2,     2,     2,     2,
299        2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
300        2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
301        2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
302        2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
303        2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
304        2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
305        2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
306        2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
307        2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
308        2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
309        2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
310        2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
311        2,     2,     2,     2,     2,     2,     1,     2,     3,     4,
312        5,     6,     7,     8,     9,    10,    11,    12,    13,    14,
313       15,    16,    17,    18,    19,    20,    21,    22,    23,    24,
314       25,    26,    27,    30,    31,    34,    35,    41,    42,    43,
315       44
316 };
317 
318 #if YYDEBUG
319 /* YYPRHS[YYN] -- Index of the first RHS symbol of rule number YYN in
320    YYRHS.  */
321 static const unsigned char yyprhs[] =
322 {
323        0,     0,     3,     5,     7,     9,    11,    13,    15,    17,
324       19,    21,    23,    25,    29,    31,    34,    37,    41,    45,
325       49,    53,    57,    61,    65,    69,    73,    77,    81,    85,
326       89,    93,    97,   101,   105,   109,   111,   113,   115,   117,
327      119,   121,   125,   127,   130,   132,   135,   139,   144,   148,
328      153,   155,   157,   162,   166,   171,   175,   182
329 };
330 
331 /* YYRHS -- A `-1'-separated list of the rules' RHS. */
332 static const yysigned_char yyrhs[] =
333 {
334       49,     0,    -1,    51,    -1,     6,    -1,     7,    -1,     8,
335       -1,    50,    -1,    56,    -1,     3,    -1,     4,    -1,    18,
336       -1,    19,    -1,    20,    -1,    21,    45,    46,    -1,    16,
337       -1,    37,    51,    -1,    43,    51,    -1,    51,    36,    51,
338       -1,    51,    37,    51,    -1,    51,    38,    51,    -1,    51,
339       39,    51,    -1,    51,    32,    51,    -1,    51,    33,    51,
340       -1,    51,    29,    51,    -1,    51,    28,    51,    -1,    51,
341       40,    51,    -1,    51,    42,    51,    -1,    51,    41,    51,
342       -1,    51,    35,    51,    -1,    51,    34,    51,    -1,    51,
343       31,    51,    -1,    51,    30,    51,    -1,    51,    27,    51,
344       -1,    51,    26,    51,    -1,    45,    51,    46,    -1,    51,
345       -1,    11,    -1,     9,    -1,    10,    -1,     5,    -1,    52,
346       -1,    53,    47,    52,    -1,     3,    -1,    37,     3,    -1,
347        4,    -1,    37,     4,    -1,    54,    47,     3,    -1,    54,
348       47,    37,     3,    -1,    54,    47,     4,    -1,    54,    47,
349       37,     4,    -1,    54,    -1,    14,    -1,    12,    45,    53,
350       46,    -1,    12,    45,    46,    -1,    15,    45,    53,    46,
351       -1,    15,    45,    46,    -1,    13,    45,    52,    47,    55,
352       46,    -1,    17,    45,    53,    46,    -1
353 };
354 
355 /* YYRLINE[YYN] -- source line where rule number YYN was defined.  */
356 static const unsigned char yyrline[] =
357 {
358        0,    61,    61,    65,    66,    67,    71,    72,    73,    74,
359       75,    76,    77,    78,    79,    80,    81,    82,    83,    84,
360       85,    86,    87,    88,    89,    90,    91,    92,    93,    94,
361       95,    96,    97,    98,    99,   103,   104,   105,   106,   107,
362      111,   112,   116,   117,   118,   119,   120,   121,   122,   123,
363      127,   128,   132,   133,   134,   135,   136,   140
364 };
365 #endif
366 
367 #if YYDEBUG || YYERROR_VERBOSE
368 /* YYTNME[SYMBOL-NUM] -- String name of the symbol SYMBOL-NUM.
369    First, the terminals, then, starting at YYNTOKENS, nonterminals. */
370 static const char *const yytname[] =
371 {
372   "$end", "error", "$undefined", "TOK_CONST_INT", "TOK_CONST_FLOAT",
373   "TOK_CONST_STRING", "TOK_ATTR_INT", "TOK_ATTR_BITS", "TOK_ATTR_FLOAT",
374   "TOK_ATTR_MVA32", "TOK_ATTR_MVA64", "TOK_ATTR_STRING", "TOK_FUNC",
375   "TOK_FUNC_IN", "TOK_USERVAR", "TOK_UDF", "TOK_HOOK_IDENT",
376   "TOK_HOOK_FUNC", "TOK_ATID", "TOK_ATWEIGHT", "TOK_ID", "TOK_WEIGHT",
377   "TOK_COUNT", "TOK_DISTINCT", "TOK_CONST_LIST", "TOK_ATTR_SINT",
378   "TOK_OR", "TOK_AND", "'|'", "'&'", "TOK_NE", "TOK_EQ", "'<'", "'>'",
379   "TOK_GTE", "TOK_LTE", "'+'", "'-'", "'*'", "'/'", "'%'", "TOK_MOD",
380   "TOK_DIV", "TOK_NOT", "TOK_NEG", "'('", "')'", "','", "$accept",
381   "exprline", "attr", "expr", "arg", "arglist", "constlist",
382   "constlist_or_uservar", "function", 0
383 };
384 #endif
385 
386 # ifdef YYPRINT
387 /* YYTOKNUM[YYLEX-NUM] -- Internal token number corresponding to
388    token YYLEX-NUM.  */
389 static const unsigned short yytoknum[] =
390 {
391        0,   256,   257,   258,   259,   260,   261,   262,   263,   264,
392      265,   266,   267,   268,   269,   270,   271,   272,   273,   274,
393      275,   276,   277,   278,   279,   280,   281,   282,   124,    38,
394      283,   284,    60,    62,   285,   286,    43,    45,    42,    47,
395       37,   287,   288,   289,   290,    40,    41,    44
396 };
397 # endif
398 
399 /* YYR1[YYN] -- Symbol number of symbol that rule YYN derives.  */
400 static const unsigned char yyr1[] =
401 {
402        0,    48,    49,    50,    50,    50,    51,    51,    51,    51,
403       51,    51,    51,    51,    51,    51,    51,    51,    51,    51,
404       51,    51,    51,    51,    51,    51,    51,    51,    51,    51,
405       51,    51,    51,    51,    51,    52,    52,    52,    52,    52,
406       53,    53,    54,    54,    54,    54,    54,    54,    54,    54,
407       55,    55,    56,    56,    56,    56,    56,    56
408 };
409 
410 /* YYR2[YYN] -- Number of symbols composing right hand side of rule YYN.  */
411 static const unsigned char yyr2[] =
412 {
413        0,     2,     1,     1,     1,     1,     1,     1,     1,     1,
414        1,     1,     1,     3,     1,     2,     2,     3,     3,     3,
415        3,     3,     3,     3,     3,     3,     3,     3,     3,     3,
416        3,     3,     3,     3,     3,     1,     1,     1,     1,     1,
417        1,     3,     1,     2,     1,     2,     3,     4,     3,     4,
418        1,     1,     4,     3,     4,     3,     6,     4
419 };
420 
421 /* YYDEFACT[STATE-NAME] -- Default rule to reduce with in state
422    STATE-NUM when YYTABLE doesn't specify something else to do.  Zero
423    means the default is an error.  */
424 static const unsigned char yydefact[] =
425 {
426        0,     8,     9,     3,     4,     5,     0,     0,     0,    14,
427        0,    10,    11,    12,     0,     0,     0,     0,     0,     6,
428        2,     7,     0,     0,     0,     0,     0,    15,    16,     0,
429        1,     0,     0,     0,     0,     0,     0,     0,     0,     0,
430        0,     0,     0,     0,     0,     0,     0,     0,    39,    37,
431       38,    36,    53,    35,    40,     0,     0,    55,     0,     0,
432       13,    34,    33,    32,    24,    23,    31,    30,    21,    22,
433       29,    28,    17,    18,    19,    20,    25,    27,    26,    52,
434        0,     0,    54,    57,    41,    42,    44,    51,     0,    50,
435        0,    43,    45,     0,    56,    46,    48,     0,    47,    49
436 };
437 
438 /* YYDEFGOTO[NTERM-NUM]. */
439 static const yysigned_char yydefgoto[] =
440 {
441       -1,    18,    19,    53,    54,    55,    89,    90,    21
442 };
443 
444 /* YYPACT[STATE-NUM] -- Index in YYTABLE of the portion describing
445    STATE-NUM.  */
446 #define YYPACT_NINF -28
447 static const short yypact[] =
448 {
449      186,   -28,   -28,   -28,   -28,   -28,   -14,     9,    11,   -28,
450       24,   -28,   -28,   -28,    52,   186,   186,   186,   139,   -28,
451      227,   -28,    55,   143,    99,   143,    53,   -28,   -28,   206,
452      -28,   186,   186,   186,   186,   186,   186,   186,   186,   186,
453      186,   186,   186,   186,   186,   186,   186,   186,   -28,   -28,
454      -28,   -28,   -28,   227,   -28,     3,    66,   -28,     5,    47,
455      -28,   -28,   243,    49,   -27,    91,   133,   133,   -13,   -13,
456      -13,   -13,   170,   170,   -28,   -28,   -28,   -28,   -28,   -28,
457      143,    16,   -28,   -28,   -28,   -28,   -28,   -28,    92,    93,
458       95,   -28,   -28,    18,   -28,   -28,   -28,   131,   -28,   -28
459 };
460 
461 /* YYPGOTO[NTERM-NUM].  */
462 static const yysigned_char yypgoto[] =
463 {
464      -28,   -28,   -28,     1,   -23,   113,   -28,   -28,   -28
465 };
466 
467 /* YYTABLE[YYPACT[STATE-NUM]].  What to do in state STATE-NUM.  If
468    positive, shift that token.  If negative, reduce the rule which
469    number is the opposite.  If zero, do what YYDEFACT says.
470    If YYTABLE_NINF, syntax error.  */
471 #define YYTABLE_NINF -1
472 static const unsigned char yytable[] =
473 {
474       56,    20,    34,    35,    36,    37,    38,    39,    40,    41,
475       42,    43,    44,    45,    46,    47,    27,    28,    29,    85,
476       86,    95,    96,    41,    42,    43,    44,    45,    46,    47,
477       87,    22,    62,    63,    64,    65,    66,    67,    68,    69,
478       70,    71,    72,    73,    74,    75,    76,    77,    78,    79,
479       80,    82,    80,    88,    23,    97,    24,    84,     1,     2,
480       48,     3,     4,     5,    49,    50,    51,     6,     7,    25,
481        8,     9,    10,    11,    12,    13,    14,    33,    34,    35,
482       36,    37,    38,    39,    40,    41,    42,    43,    44,    45,
483       46,    47,    15,    83,    80,    91,    92,    26,    16,    60,
484       17,    52,     1,     2,    48,     3,     4,     5,    49,    50,
485       51,     6,     7,    81,     8,     9,    10,    11,    12,    13,
486       14,    35,    36,    37,    38,    39,    40,    41,    42,    43,
487       44,    45,    46,    47,    98,    99,    15,    58,    59,    30,
488       93,    94,    16,     0,    17,    57,     1,     2,    48,     3,
489        4,     5,    49,    50,    51,     6,     7,     0,     8,     9,
490       10,    11,    12,    13,    14,    37,    38,    39,    40,    41,
491       42,    43,    44,    45,    46,    47,     0,     0,     0,     0,
492       15,     0,     0,     0,     0,     0,    16,     0,    17,     1,
493        2,     0,     3,     4,     5,     0,     0,     0,     6,     7,
494        0,     8,     9,    10,    11,    12,    13,    14,    43,    44,
495       45,    46,    47,     0,     0,     0,     0,     0,     0,     0,
496        0,     0,     0,    15,     0,     0,     0,     0,     0,    16,
497        0,    17,    31,    32,    33,    34,    35,    36,    37,    38,
498       39,    40,    41,    42,    43,    44,    45,    46,    47,     0,
499        0,     0,    61,    31,    32,    33,    34,    35,    36,    37,
500       38,    39,    40,    41,    42,    43,    44,    45,    46,    47,
501       32,    33,    34,    35,    36,    37,    38,    39,    40,    41,
502       42,    43,    44,    45,    46,    47
503 };
504 
505 static const yysigned_char yycheck[] =
506 {
507       23,     0,    29,    30,    31,    32,    33,    34,    35,    36,
508       37,    38,    39,    40,    41,    42,    15,    16,    17,     3,
509        4,     3,     4,    36,    37,    38,    39,    40,    41,    42,
510       14,    45,    31,    32,    33,    34,    35,    36,    37,    38,
511       39,    40,    41,    42,    43,    44,    45,    46,    47,    46,
512       47,    46,    47,    37,    45,    37,    45,    80,     3,     4,
513        5,     6,     7,     8,     9,    10,    11,    12,    13,    45,
514       15,    16,    17,    18,    19,    20,    21,    28,    29,    30,
515       31,    32,    33,    34,    35,    36,    37,    38,    39,    40,
516       41,    42,    37,    46,    47,     3,     4,    45,    43,    46,
517       45,    46,     3,     4,     5,     6,     7,     8,     9,    10,
518       11,    12,    13,    47,    15,    16,    17,    18,    19,    20,
519       21,    30,    31,    32,    33,    34,    35,    36,    37,    38,
520       39,    40,    41,    42,     3,     4,    37,    24,    25,     0,
521       47,    46,    43,    -1,    45,    46,     3,     4,     5,     6,
522        7,     8,     9,    10,    11,    12,    13,    -1,    15,    16,
523       17,    18,    19,    20,    21,    32,    33,    34,    35,    36,
524       37,    38,    39,    40,    41,    42,    -1,    -1,    -1,    -1,
525       37,    -1,    -1,    -1,    -1,    -1,    43,    -1,    45,     3,
526        4,    -1,     6,     7,     8,    -1,    -1,    -1,    12,    13,
527       -1,    15,    16,    17,    18,    19,    20,    21,    38,    39,
528       40,    41,    42,    -1,    -1,    -1,    -1,    -1,    -1,    -1,
529       -1,    -1,    -1,    37,    -1,    -1,    -1,    -1,    -1,    43,
530       -1,    45,    26,    27,    28,    29,    30,    31,    32,    33,
531       34,    35,    36,    37,    38,    39,    40,    41,    42,    -1,
532       -1,    -1,    46,    26,    27,    28,    29,    30,    31,    32,
533       33,    34,    35,    36,    37,    38,    39,    40,    41,    42,
534       27,    28,    29,    30,    31,    32,    33,    34,    35,    36,
535       37,    38,    39,    40,    41,    42
536 };
537 
538 /* YYSTOS[STATE-NUM] -- The (internal number of the) accessing
539    symbol of state STATE-NUM.  */
540 static const unsigned char yystos[] =
541 {
542        0,     3,     4,     6,     7,     8,    12,    13,    15,    16,
543       17,    18,    19,    20,    21,    37,    43,    45,    49,    50,
544       51,    56,    45,    45,    45,    45,    45,    51,    51,    51,
545        0,    26,    27,    28,    29,    30,    31,    32,    33,    34,
546       35,    36,    37,    38,    39,    40,    41,    42,     5,     9,
547       10,    11,    46,    51,    52,    53,    52,    46,    53,    53,
548       46,    46,    51,    51,    51,    51,    51,    51,    51,    51,
549       51,    51,    51,    51,    51,    51,    51,    51,    51,    46,
550       47,    47,    46,    46,    52,     3,     4,    14,    37,    54,
551       55,     3,     4,    47,    46,     3,     4,    37,     3,     4
552 };
553 
554 #if ! defined (YYSIZE_T) && defined (__SIZE_TYPE__)
555 # define YYSIZE_T __SIZE_TYPE__
556 #endif
557 #if ! defined (YYSIZE_T) && defined (size_t)
558 # define YYSIZE_T size_t
559 #endif
560 #if ! defined (YYSIZE_T)
561 # if defined (__STDC__) || defined (__cplusplus)
562 #  include <stddef.h> /* INFRINGES ON USER NAME SPACE */
563 #  define YYSIZE_T size_t
564 # endif
565 #endif
566 #if ! defined (YYSIZE_T)
567 # define YYSIZE_T unsigned int
568 #endif
569 
570 #define yyerrok		(yyerrstatus = 0)
571 #define yyclearin	(yychar = YYEMPTY)
572 #define YYEMPTY		(-2)
573 #define YYEOF		0
574 
575 #define YYACCEPT	goto yyacceptlab
576 #define YYABORT		goto yyabortlab
577 #define YYERROR		goto yyerrlab1
578 
579 /* Like YYERROR except do call yyerror.  This remains here temporarily
580    to ease the transition to the new meaning of YYERROR, for GCC.
581    Once GCC version 2 has supplanted version 1, this can go.  */
582 
583 #define YYFAIL		goto yyerrlab
584 
585 #define YYRECOVERING()  (!!yyerrstatus)
586 
587 #define YYBACKUP(Token, Value)					\
588 do								\
589   if (yychar == YYEMPTY && yylen == 1)				\
590     {								\
591       yychar = (Token);						\
592       yylval = (Value);						\
593       yytoken = YYTRANSLATE (yychar);				\
594       YYPOPSTACK;						\
595       goto yybackup;						\
596     }								\
597   else								\
598     { 								\
599       yyerror (pParser, "syntax error: cannot back up");\
600       YYERROR;							\
601     }								\
602 while (0)
603 
604 #define YYTERROR	1
605 #define YYERRCODE	256
606 
607 /* YYLLOC_DEFAULT -- Compute the default location (before the actions
608    are run).  */
609 
610 #ifndef YYLLOC_DEFAULT
611 # define YYLLOC_DEFAULT(Current, Rhs, N)         \
612   Current.first_line   = Rhs[1].first_line;      \
613   Current.first_column = Rhs[1].first_column;    \
614   Current.last_line    = Rhs[N].last_line;       \
615   Current.last_column  = Rhs[N].last_column;
616 #endif
617 
618 /* YYLEX -- calling `yylex' with the right arguments.  */
619 
620 #ifdef YYLEX_PARAM
621 # define YYLEX yylex (&yylval, YYLEX_PARAM)
622 #else
623 # define YYLEX yylex (&yylval, pParser)
624 #endif
625 
626 /* Enable debugging if requested.  */
627 #if YYDEBUG
628 
629 # ifndef YYFPRINTF
630 #  include <stdio.h> /* INFRINGES ON USER NAME SPACE */
631 #  define YYFPRINTF fprintf
632 # endif
633 
634 # define YYDPRINTF(Args)			\
635 do {						\
636   if (yydebug)					\
637     YYFPRINTF Args;				\
638 } while (0)
639 
640 # define YYDSYMPRINT(Args)			\
641 do {						\
642   if (yydebug)					\
643     yysymprint Args;				\
644 } while (0)
645 
646 # define YYDSYMPRINTF(Title, Token, Value, Location)		\
647 do {								\
648   if (yydebug)							\
649     {								\
650       YYFPRINTF (stderr, "%s ", Title);				\
651       yysymprint (stderr, 					\
652                   Token, Value);	\
653       YYFPRINTF (stderr, "\n");					\
654     }								\
655 } while (0)
656 
657 /*------------------------------------------------------------------.
658 | yy_stack_print -- Print the state stack from its BOTTOM up to its |
659 | TOP (cinluded).                                                   |
660 `------------------------------------------------------------------*/
661 
662 #if defined (__STDC__) || defined (__cplusplus)
663 static void
yy_stack_print(short * bottom,short * top)664 yy_stack_print (short *bottom, short *top)
665 #else
666 static void
667 yy_stack_print (bottom, top)
668     short *bottom;
669     short *top;
670 #endif
671 {
672   YYFPRINTF (stderr, "Stack now");
673   for (/* Nothing. */; bottom <= top; ++bottom)
674     YYFPRINTF (stderr, " %d", *bottom);
675   YYFPRINTF (stderr, "\n");
676 }
677 
678 # define YY_STACK_PRINT(Bottom, Top)				\
679 do {								\
680   if (yydebug)							\
681     yy_stack_print ((Bottom), (Top));				\
682 } while (0)
683 
684 
685 /*------------------------------------------------.
686 | Report that the YYRULE is going to be reduced.  |
687 `------------------------------------------------*/
688 
689 #if defined (__STDC__) || defined (__cplusplus)
690 static void
yy_reduce_print(int yyrule)691 yy_reduce_print (int yyrule)
692 #else
693 static void
694 yy_reduce_print (yyrule)
695     int yyrule;
696 #endif
697 {
698   int yyi;
699   unsigned int yylineno = yyrline[yyrule];
700   YYFPRINTF (stderr, "Reducing stack by rule %d (line %u), ",
701              yyrule - 1, yylineno);
702   /* Print the symbols being reduced, and their result.  */
703   for (yyi = yyprhs[yyrule]; 0 <= yyrhs[yyi]; yyi++)
704     YYFPRINTF (stderr, "%s ", yytname [yyrhs[yyi]]);
705   YYFPRINTF (stderr, "-> %s\n", yytname [yyr1[yyrule]]);
706 }
707 
708 # define YY_REDUCE_PRINT(Rule)		\
709 do {					\
710   if (yydebug)				\
711     yy_reduce_print (Rule);		\
712 } while (0)
713 
714 /* Nonzero means print parse trace.  It is left uninitialized so that
715    multiple parsers can coexist.  */
716 int yydebug;
717 #else /* !YYDEBUG */
718 # define YYDPRINTF(Args)
719 # define YYDSYMPRINT(Args)
720 # define YYDSYMPRINTF(Title, Token, Value, Location)
721 # define YY_STACK_PRINT(Bottom, Top)
722 # define YY_REDUCE_PRINT(Rule)
723 #endif /* !YYDEBUG */
724 
725 
726 /* YYINITDEPTH -- initial size of the parser's stacks.  */
727 #ifndef	YYINITDEPTH
728 # define YYINITDEPTH 200
729 #endif
730 
731 /* YYMAXDEPTH -- maximum size the stacks can grow to (effective only
732    if the built-in stack extension method is used).
733 
734    Do not make this value too large; the results are undefined if
735    SIZE_MAX < YYSTACK_BYTES (YYMAXDEPTH)
736    evaluated with infinite-precision integer arithmetic.  */
737 
738 #if YYMAXDEPTH == 0
739 # undef YYMAXDEPTH
740 #endif
741 
742 #ifndef YYMAXDEPTH
743 # define YYMAXDEPTH 10000
744 #endif
745 
746 
747 
748 #if YYERROR_VERBOSE
749 
750 # ifndef yystrlen
751 #  if defined (__GLIBC__) && defined (_STRING_H)
752 #   define yystrlen strlen
753 #  else
754 /* Return the length of YYSTR.  */
755 static YYSIZE_T
756 #   if defined (__STDC__) || defined (__cplusplus)
yystrlen(const char * yystr)757 yystrlen (const char *yystr)
758 #   else
759 yystrlen (yystr)
760      const char *yystr;
761 #   endif
762 {
763   register const char *yys = yystr;
764 
765   while (*yys++ != '\0')
766     continue;
767 
768   return yys - yystr - 1;
769 }
770 #  endif
771 # endif
772 
773 # ifndef yystpcpy
774 #  if defined (__GLIBC__) && defined (_STRING_H) && defined (_GNU_SOURCE)
775 #   define yystpcpy stpcpy
776 #  else
777 /* Copy YYSRC to YYDEST, returning the address of the terminating '\0' in
778    YYDEST.  */
779 static char *
780 #   if defined (__STDC__) || defined (__cplusplus)
yystpcpy(char * yydest,const char * yysrc)781 yystpcpy (char *yydest, const char *yysrc)
782 #   else
783 yystpcpy (yydest, yysrc)
784      char *yydest;
785      const char *yysrc;
786 #   endif
787 {
788   register char *yyd = yydest;
789   register const char *yys = yysrc;
790 
791   while ((*yyd++ = *yys++) != '\0')
792     continue;
793 
794   return yyd - 1;
795 }
796 #  endif
797 # endif
798 
799 #endif /* !YYERROR_VERBOSE */
800 
801 
802 
803 #if YYDEBUG
804 /*--------------------------------.
805 | Print this symbol on YYOUTPUT.  |
806 `--------------------------------*/
807 
808 #if defined (__STDC__) || defined (__cplusplus)
809 static void
yysymprint(FILE * yyoutput,int yytype,YYSTYPE * yyvaluep)810 yysymprint (FILE *yyoutput, int yytype, YYSTYPE *yyvaluep)
811 #else
812 static void
813 yysymprint (yyoutput, yytype, yyvaluep)
814     FILE *yyoutput;
815     int yytype;
816     YYSTYPE *yyvaluep;
817 #endif
818 {
819   /* Pacify ``unused variable'' warnings.  */
820   (void) yyvaluep;
821 
822   if (yytype < YYNTOKENS)
823     {
824       YYFPRINTF (yyoutput, "token %s (", yytname[yytype]);
825 # ifdef YYPRINT
826       YYPRINT (yyoutput, yytoknum[yytype], *yyvaluep);
827 # endif
828     }
829   else
830     YYFPRINTF (yyoutput, "nterm %s (", yytname[yytype]);
831 
832   switch (yytype)
833     {
834       default:
835         break;
836     }
837   YYFPRINTF (yyoutput, ")");
838 }
839 
840 #endif /* ! YYDEBUG */
841 /*-----------------------------------------------.
842 | Release the memory associated to this symbol.  |
843 `-----------------------------------------------*/
844 
845 #if defined (__STDC__) || defined (__cplusplus)
846 static void
yydestruct(int yytype,YYSTYPE * yyvaluep)847 yydestruct (int yytype, YYSTYPE *yyvaluep)
848 #else
849 static void
850 yydestruct (yytype, yyvaluep)
851     int yytype;
852     YYSTYPE *yyvaluep;
853 #endif
854 {
855   /* Pacify ``unused variable'' warnings.  */
856   (void) yyvaluep;
857 
858   switch (yytype)
859     {
860 
861       default:
862         break;
863     }
864 }
865 
866 
867 /* Prevent warnings from -Wmissing-prototypes.  */
868 
869 #ifdef YYPARSE_PARAM
870 # if defined (__STDC__) || defined (__cplusplus)
871 int yyparse (void *YYPARSE_PARAM);
872 # else
873 int yyparse ();
874 # endif
875 #else /* ! YYPARSE_PARAM */
876 #if defined (__STDC__) || defined (__cplusplus)
877 int yyparse ( ExprParser_t * pParser );
878 #else
879 int yyparse ();
880 #endif
881 #endif /* ! YYPARSE_PARAM */
882 
883 
884 
885 
886 
887 
888 /*----------.
889 | yyparse.  |
890 `----------*/
891 
892 #ifdef YYPARSE_PARAM
893 # if defined (__STDC__) || defined (__cplusplus)
yyparse(void * YYPARSE_PARAM)894 int yyparse (void *YYPARSE_PARAM)
895 # else
896 int yyparse (YYPARSE_PARAM)
897   void *YYPARSE_PARAM;
898 # endif
899 #else /* ! YYPARSE_PARAM */
900 #if defined (__STDC__) || defined (__cplusplus)
901 int
902 yyparse ( ExprParser_t * pParser )
903 #else
904 int
905 yyparse (pParser)
906      ExprParser_t * pParser ;
907 #endif
908 #endif
909 {
910   /* The lookahead symbol.  */
911 int yychar;
912 
913 /* The semantic value of the lookahead symbol.  */
914 YYSTYPE yylval;
915 
916 /* Number of syntax errors so far.  */
917 int yynerrs;
918 
919   register int yystate;
920   register int yyn;
921   int yyresult;
922   /* Number of tokens to shift before error messages enabled.  */
923   int yyerrstatus;
924   /* Lookahead token as an internal (translated) token number.  */
925   int yytoken = 0;
926 
927   /* Three stacks and their tools:
928      `yyss': related to states,
929      `yyvs': related to semantic values,
930      `yyls': related to locations.
931 
932      Refer to the stacks thru separate pointers, to allow yyoverflow
933      to reallocate them elsewhere.  */
934 
935   /* The state stack.  */
936   short	yyssa[YYINITDEPTH];
937   short *yyss = yyssa;
938   register short *yyssp;
939 
940   /* The semantic value stack.  */
941   YYSTYPE yyvsa[YYINITDEPTH];
942   YYSTYPE *yyvs = yyvsa;
943   register YYSTYPE *yyvsp;
944 
945 
946 
947 #define YYPOPSTACK   (yyvsp--, yyssp--)
948 
949   YYSIZE_T yystacksize = YYINITDEPTH;
950 
951   /* The variables used to return semantic value and location from the
952      action routines.  */
953   YYSTYPE yyval;
954 
955 
956   /* When reducing, the number of symbols on the RHS of the reduced
957      rule.  */
958   int yylen;
959 
960   YYDPRINTF ((stderr, "Starting parse\n"));
961 
962   yystate = 0;
963   yyerrstatus = 0;
964   yynerrs = 0;
965   yychar = YYEMPTY;		/* Cause a token to be read.  */
966 
967   /* Initialize stack pointers.
968      Waste one element of value and location stack
969      so that they stay on the same level as the state stack.
970      The wasted elements are never initialized.  */
971 
972   yyssp = yyss;
973   yyvsp = yyvs;
974 
975   goto yysetstate;
976 
977 /*------------------------------------------------------------.
978 | yynewstate -- Push a new state, which is found in yystate.  |
979 `------------------------------------------------------------*/
980  yynewstate:
981   /* In all cases, when you get here, the value and location stacks
982      have just been pushed. so pushing a state here evens the stacks.
983      */
984   yyssp++;
985 
986  yysetstate:
987   *yyssp = yystate;
988 
989   if (yyss + yystacksize - 1 <= yyssp)
990     {
991       /* Get the current used size of the three stacks, in elements.  */
992       YYSIZE_T yysize = yyssp - yyss + 1;
993 
994 #ifdef yyoverflow
995       {
996 	/* Give user a chance to reallocate the stack. Use copies of
997 	   these so that the &'s don't force the real ones into
998 	   memory.  */
999 	YYSTYPE *yyvs1 = yyvs;
1000 	short *yyss1 = yyss;
1001 
1002 
1003 	/* Each stack pointer address is followed by the size of the
1004 	   data in use in that stack, in bytes.  This used to be a
1005 	   conditional around just the two extra args, but that might
1006 	   be undefined if yyoverflow is a macro.  */
1007 	yyoverflow ("parser stack overflow",
1008 		    &yyss1, yysize * sizeof (*yyssp),
1009 		    &yyvs1, yysize * sizeof (*yyvsp),
1010 
1011 		    &yystacksize);
1012 
1013 	yyss = yyss1;
1014 	yyvs = yyvs1;
1015       }
1016 #else /* no yyoverflow */
1017 # ifndef YYSTACK_RELOCATE
1018       goto yyoverflowlab;
1019 # else
1020       /* Extend the stack our own way.  */
1021       if (YYMAXDEPTH <= yystacksize)
1022 	goto yyoverflowlab;
1023       yystacksize *= 2;
1024       if (YYMAXDEPTH < yystacksize)
1025 	yystacksize = YYMAXDEPTH;
1026 
1027       {
1028 	short *yyss1 = yyss;
1029 	union yyalloc *yyptr =
1030 	  (union yyalloc *) YYSTACK_ALLOC (YYSTACK_BYTES (yystacksize));
1031 	if (! yyptr)
1032 	  goto yyoverflowlab;
1033 	YYSTACK_RELOCATE (yyss);
1034 	YYSTACK_RELOCATE (yyvs);
1035 
1036 #  undef YYSTACK_RELOCATE
1037 	if (yyss1 != yyssa)
1038 	  YYSTACK_FREE (yyss1);
1039       }
1040 # endif
1041 #endif /* no yyoverflow */
1042 
1043       yyssp = yyss + yysize - 1;
1044       yyvsp = yyvs + yysize - 1;
1045 
1046 
1047       YYDPRINTF ((stderr, "Stack size increased to %lu\n",
1048 		  (unsigned long int) yystacksize));
1049 
1050       if (yyss + yystacksize - 1 <= yyssp)
1051 	YYABORT;
1052     }
1053 
1054   YYDPRINTF ((stderr, "Entering state %d\n", yystate));
1055 
1056   goto yybackup;
1057 
1058 /*-----------.
1059 | yybackup.  |
1060 `-----------*/
1061 yybackup:
1062 
1063 /* Do appropriate processing given the current state.  */
1064 /* Read a lookahead token if we need one and don't already have one.  */
1065 /* yyresume: */
1066 
1067   /* First try to decide what to do without reference to lookahead token.  */
1068 
1069   yyn = yypact[yystate];
1070   if (yyn == YYPACT_NINF)
1071     goto yydefault;
1072 
1073   /* Not known => get a lookahead token if don't already have one.  */
1074 
1075   /* YYCHAR is either YYEMPTY or YYEOF or a valid lookahead symbol.  */
1076   if (yychar == YYEMPTY)
1077     {
1078       YYDPRINTF ((stderr, "Reading a token: "));
1079       yychar = YYLEX;
1080     }
1081 
1082   if (yychar <= YYEOF)
1083     {
1084       yychar = yytoken = YYEOF;
1085       YYDPRINTF ((stderr, "Now at end of input.\n"));
1086     }
1087   else
1088     {
1089       yytoken = YYTRANSLATE (yychar);
1090       YYDSYMPRINTF ("Next token is", yytoken, &yylval, &yylloc);
1091     }
1092 
1093   /* If the proper action on seeing token YYTOKEN is to reduce or to
1094      detect an error, take that action.  */
1095   yyn += yytoken;
1096   if (yyn < 0 || YYLAST < yyn || yycheck[yyn] != yytoken)
1097     goto yydefault;
1098   yyn = yytable[yyn];
1099   if (yyn <= 0)
1100     {
1101       if (yyn == 0 || yyn == YYTABLE_NINF)
1102 	goto yyerrlab;
1103       yyn = -yyn;
1104       goto yyreduce;
1105     }
1106 
1107   if (yyn == YYFINAL)
1108     YYACCEPT;
1109 
1110   /* Shift the lookahead token.  */
1111   YYDPRINTF ((stderr, "Shifting token %s, ", yytname[yytoken]));
1112 
1113   /* Discard the token being shifted unless it is eof.  */
1114   if (yychar != YYEOF)
1115     yychar = YYEMPTY;
1116 
1117   *++yyvsp = yylval;
1118 
1119 
1120   /* Count tokens shifted since error; after three, turn off error
1121      status.  */
1122   if (yyerrstatus)
1123     yyerrstatus--;
1124 
1125   yystate = yyn;
1126   goto yynewstate;
1127 
1128 
1129 /*-----------------------------------------------------------.
1130 | yydefault -- do the default action for the current state.  |
1131 `-----------------------------------------------------------*/
1132 yydefault:
1133   yyn = yydefact[yystate];
1134   if (yyn == 0)
1135     goto yyerrlab;
1136   goto yyreduce;
1137 
1138 
1139 /*-----------------------------.
1140 | yyreduce -- Do a reduction.  |
1141 `-----------------------------*/
1142 yyreduce:
1143   /* yyn is the number of a rule to reduce with.  */
1144   yylen = yyr2[yyn];
1145 
1146   /* If YYLEN is nonzero, implement the default value of the action:
1147      `$$ = $1'.
1148 
1149      Otherwise, the following line sets YYVAL to garbage.
1150      This behavior is undocumented and Bison
1151      users should not rely upon it.  Assigning to YYVAL
1152      unconditionally makes the parser a bit smaller, and it avoids a
1153      GCC warning that YYVAL may be used uninitialized.  */
1154   yyval = yyvsp[1-yylen];
1155 
1156 
1157   YY_REDUCE_PRINT (yyn);
1158   switch (yyn)
1159     {
1160         case 2:
1161 
1162     { pParser->m_iParsed = yyvsp[0].iNode; ;}
1163     break;
1164 
1165   case 3:
1166 
1167     { yyval.iNode = pParser->AddNodeAttr ( TOK_ATTR_INT, yyvsp[0].iAttrLocator ); ;}
1168     break;
1169 
1170   case 4:
1171 
1172     { yyval.iNode = pParser->AddNodeAttr ( TOK_ATTR_BITS, yyvsp[0].iAttrLocator ); ;}
1173     break;
1174 
1175   case 5:
1176 
1177     { yyval.iNode = pParser->AddNodeAttr ( TOK_ATTR_FLOAT, yyvsp[0].iAttrLocator ); ;}
1178     break;
1179 
1180   case 8:
1181 
1182     { yyval.iNode = pParser->AddNodeInt ( yyvsp[0].iConst ); ;}
1183     break;
1184 
1185   case 9:
1186 
1187     { yyval.iNode = pParser->AddNodeFloat ( yyvsp[0].fConst ); ;}
1188     break;
1189 
1190   case 10:
1191 
1192     { yyval.iNode = pParser->AddNodeID(); ;}
1193     break;
1194 
1195   case 11:
1196 
1197     { yyval.iNode = pParser->AddNodeWeight(); ;}
1198     break;
1199 
1200   case 12:
1201 
1202     { yyval.iNode = pParser->AddNodeID(); ;}
1203     break;
1204 
1205   case 13:
1206 
1207     { yyval.iNode = pParser->AddNodeWeight(); ;}
1208     break;
1209 
1210   case 14:
1211 
1212     { yyval.iNode = pParser->AddNodeHookIdent ( yyvsp[0].iNode ); ;}
1213     break;
1214 
1215   case 15:
1216 
1217     { yyval.iNode = pParser->AddNodeOp ( TOK_NEG, yyvsp[0].iNode, -1 ); ;}
1218     break;
1219 
1220   case 16:
1221 
1222     { yyval.iNode = pParser->AddNodeOp ( TOK_NOT, yyvsp[0].iNode, -1 ); if ( yyval.iNode<0 ) YYERROR; ;}
1223     break;
1224 
1225   case 17:
1226 
1227     { yyval.iNode = pParser->AddNodeOp ( '+', yyvsp[-2].iNode, yyvsp[0].iNode ); ;}
1228     break;
1229 
1230   case 18:
1231 
1232     { yyval.iNode = pParser->AddNodeOp ( '-', yyvsp[-2].iNode, yyvsp[0].iNode ); ;}
1233     break;
1234 
1235   case 19:
1236 
1237     { yyval.iNode = pParser->AddNodeOp ( '*', yyvsp[-2].iNode, yyvsp[0].iNode ); ;}
1238     break;
1239 
1240   case 20:
1241 
1242     { yyval.iNode = pParser->AddNodeOp ( '/', yyvsp[-2].iNode, yyvsp[0].iNode ); ;}
1243     break;
1244 
1245   case 21:
1246 
1247     { yyval.iNode = pParser->AddNodeOp ( '<', yyvsp[-2].iNode, yyvsp[0].iNode ); ;}
1248     break;
1249 
1250   case 22:
1251 
1252     { yyval.iNode = pParser->AddNodeOp ( '>', yyvsp[-2].iNode, yyvsp[0].iNode ); ;}
1253     break;
1254 
1255   case 23:
1256 
1257     { yyval.iNode = pParser->AddNodeOp ( '&', yyvsp[-2].iNode, yyvsp[0].iNode ); ;}
1258     break;
1259 
1260   case 24:
1261 
1262     { yyval.iNode = pParser->AddNodeOp ( '|', yyvsp[-2].iNode, yyvsp[0].iNode ); ;}
1263     break;
1264 
1265   case 25:
1266 
1267     { yyval.iNode = pParser->AddNodeOp ( '%', yyvsp[-2].iNode, yyvsp[0].iNode ); ;}
1268     break;
1269 
1270   case 26:
1271 
1272     { yyval.iNode = pParser->AddNodeFunc ( FUNC_IDIV, pParser->AddNodeOp ( ',', yyvsp[-2].iNode, yyvsp[0].iNode ) ); ;}
1273     break;
1274 
1275   case 27:
1276 
1277     { yyval.iNode = pParser->AddNodeOp ( '%', yyvsp[-2].iNode, yyvsp[0].iNode ); ;}
1278     break;
1279 
1280   case 28:
1281 
1282     { yyval.iNode = pParser->AddNodeOp ( TOK_LTE, yyvsp[-2].iNode, yyvsp[0].iNode ); ;}
1283     break;
1284 
1285   case 29:
1286 
1287     { yyval.iNode = pParser->AddNodeOp ( TOK_GTE, yyvsp[-2].iNode, yyvsp[0].iNode ); ;}
1288     break;
1289 
1290   case 30:
1291 
1292     { yyval.iNode = pParser->AddNodeOp ( TOK_EQ, yyvsp[-2].iNode, yyvsp[0].iNode ); ;}
1293     break;
1294 
1295   case 31:
1296 
1297     { yyval.iNode = pParser->AddNodeOp ( TOK_NE, yyvsp[-2].iNode, yyvsp[0].iNode ); ;}
1298     break;
1299 
1300   case 32:
1301 
1302     { yyval.iNode = pParser->AddNodeOp ( TOK_AND, yyvsp[-2].iNode, yyvsp[0].iNode ); if ( yyval.iNode<0 ) YYERROR; ;}
1303     break;
1304 
1305   case 33:
1306 
1307     { yyval.iNode = pParser->AddNodeOp ( TOK_OR, yyvsp[-2].iNode, yyvsp[0].iNode ); if ( yyval.iNode<0 ) YYERROR; ;}
1308     break;
1309 
1310   case 34:
1311 
1312     { yyval.iNode = yyvsp[-1].iNode; ;}
1313     break;
1314 
1315   case 36:
1316 
1317     { yyval.iNode = pParser->AddNodeAttr ( TOK_ATTR_STRING, yyvsp[0].iAttrLocator ); ;}
1318     break;
1319 
1320   case 37:
1321 
1322     { yyval.iNode = pParser->AddNodeAttr ( TOK_ATTR_MVA32, yyvsp[0].iAttrLocator ); ;}
1323     break;
1324 
1325   case 38:
1326 
1327     { yyval.iNode = pParser->AddNodeAttr ( TOK_ATTR_MVA64, yyvsp[0].iAttrLocator ); ;}
1328     break;
1329 
1330   case 39:
1331 
1332     { yyval.iNode = pParser->AddNodeString ( yyvsp[0].iConst ); ;}
1333     break;
1334 
1335   case 41:
1336 
1337     { yyval.iNode = pParser->AddNodeOp ( ',', yyvsp[-2].iNode, yyvsp[0].iNode ); ;}
1338     break;
1339 
1340   case 42:
1341 
1342     { yyval.iNode = pParser->AddNodeConstlist ( yyvsp[0].iConst ); ;}
1343     break;
1344 
1345   case 43:
1346 
1347     { yyval.iNode = pParser->AddNodeConstlist ( -yyvsp[0].iConst );;}
1348     break;
1349 
1350   case 44:
1351 
1352     { yyval.iNode = pParser->AddNodeConstlist ( yyvsp[0].fConst ); ;}
1353     break;
1354 
1355   case 45:
1356 
1357     { yyval.iNode = pParser->AddNodeConstlist ( -yyvsp[0].fConst );;}
1358     break;
1359 
1360   case 46:
1361 
1362     { pParser->AppendToConstlist ( yyval.iNode, yyvsp[0].iConst ); ;}
1363     break;
1364 
1365   case 47:
1366 
1367     { pParser->AppendToConstlist ( yyval.iNode, -yyvsp[0].iConst );;}
1368     break;
1369 
1370   case 48:
1371 
1372     { pParser->AppendToConstlist ( yyval.iNode, yyvsp[0].fConst ); ;}
1373     break;
1374 
1375   case 49:
1376 
1377     { pParser->AppendToConstlist ( yyval.iNode, -yyvsp[0].fConst );;}
1378     break;
1379 
1380   case 51:
1381 
1382     { yyval.iNode = pParser->AddNodeUservar ( yyvsp[0].iNode ); ;}
1383     break;
1384 
1385   case 52:
1386 
1387     { yyval.iNode = pParser->AddNodeFunc ( yyvsp[-3].iFunc, yyvsp[-1].iNode ); if ( yyval.iNode<0 ) YYERROR; ;}
1388     break;
1389 
1390   case 53:
1391 
1392     { yyval.iNode = pParser->AddNodeFunc ( yyvsp[-2].iFunc, -1 ); if ( yyval.iNode<0 ) YYERROR; ;}
1393     break;
1394 
1395   case 54:
1396 
1397     { yyval.iNode = pParser->AddNodeUdf ( yyvsp[-3].iNode, yyvsp[-1].iNode ); if ( yyval.iNode<0 ) YYERROR; ;}
1398     break;
1399 
1400   case 55:
1401 
1402     { yyval.iNode = pParser->AddNodeUdf ( yyvsp[-2].iNode, -1 ); if ( yyval.iNode<0 ) YYERROR; ;}
1403     break;
1404 
1405   case 56:
1406 
1407     {
1408 			yyval.iNode = pParser->AddNodeFunc ( yyvsp[-5].iFunc, yyvsp[-3].iNode, yyvsp[-1].iNode );
1409 		;}
1410     break;
1411 
1412   case 57:
1413 
1414     {
1415 			yyval.iNode = pParser->AddNodeHookFunc ( yyvsp[-3].iNode, yyvsp[-1].iNode );
1416 			if ( yyval.iNode<0 )
1417 				YYERROR;
1418 		;}
1419     break;
1420 
1421 
1422     }
1423 
1424 /* Line 991 of yacc.c.  */
1425 
1426 
1427   yyvsp -= yylen;
1428   yyssp -= yylen;
1429 
1430 
1431   YY_STACK_PRINT (yyss, yyssp);
1432 
1433   *++yyvsp = yyval;
1434 
1435 
1436   /* Now `shift' the result of the reduction.  Determine what state
1437      that goes to, based on the state we popped back to and the rule
1438      number reduced by.  */
1439 
1440   yyn = yyr1[yyn];
1441 
1442   yystate = yypgoto[yyn - YYNTOKENS] + *yyssp;
1443   if (0 <= yystate && yystate <= YYLAST && yycheck[yystate] == *yyssp)
1444     yystate = yytable[yystate];
1445   else
1446     yystate = yydefgoto[yyn - YYNTOKENS];
1447 
1448   goto yynewstate;
1449 
1450 
1451 /*------------------------------------.
1452 | yyerrlab -- here on detecting error |
1453 `------------------------------------*/
1454 yyerrlab:
1455   /* If not already recovering from an error, report this error.  */
1456   if (!yyerrstatus)
1457     {
1458       ++yynerrs;
1459 #if YYERROR_VERBOSE
1460       yyn = yypact[yystate];
1461 
1462       if (YYPACT_NINF < yyn && yyn < YYLAST)
1463 	{
1464 	  YYSIZE_T yysize = 0;
1465 	  int yytype = YYTRANSLATE (yychar);
1466 	  char *yymsg;
1467 	  int yyx, yycount;
1468 
1469 	  yycount = 0;
1470 	  /* Start YYX at -YYN if negative to avoid negative indexes in
1471 	     YYCHECK.  */
1472 	  for (yyx = yyn < 0 ? -yyn : 0;
1473 	       yyx < (int) (sizeof (yytname) / sizeof (char *)); yyx++)
1474 	    if (yycheck[yyx + yyn] == yyx && yyx != YYTERROR)
1475 	      yysize += yystrlen (yytname[yyx]) + 15, yycount++;
1476 	  yysize += yystrlen ("syntax error, unexpected ") + 1;
1477 	  yysize += yystrlen (yytname[yytype]);
1478 	  yymsg = (char *) YYSTACK_ALLOC (yysize);
1479 	  if (yymsg != 0)
1480 	    {
1481 	      char *yyp = yystpcpy (yymsg, "syntax error, unexpected ");
1482 	      yyp = yystpcpy (yyp, yytname[yytype]);
1483 
1484 	      if (yycount < 5)
1485 		{
1486 		  yycount = 0;
1487 		  for (yyx = yyn < 0 ? -yyn : 0;
1488 		       yyx < (int) (sizeof (yytname) / sizeof (char *));
1489 		       yyx++)
1490 		    if (yycheck[yyx + yyn] == yyx && yyx != YYTERROR)
1491 		      {
1492 			const char *yyq = ! yycount ? ", expecting " : " or ";
1493 			yyp = yystpcpy (yyp, yyq);
1494 			yyp = yystpcpy (yyp, yytname[yyx]);
1495 			yycount++;
1496 		      }
1497 		}
1498 	      yyerror (pParser, yymsg);
1499 	      YYSTACK_FREE (yymsg);
1500 	    }
1501 	  else
1502 	    yyerror (pParser, "syntax error; also virtual memory exhausted");
1503 	}
1504       else
1505 #endif /* YYERROR_VERBOSE */
1506 	yyerror (pParser, "syntax error");
1507     }
1508 
1509 
1510 
1511   if (yyerrstatus == 3)
1512     {
1513       /* If just tried and failed to reuse lookahead token after an
1514 	 error, discard it.  */
1515 
1516       /* Return failure if at end of input.  */
1517       if (yychar == YYEOF)
1518         {
1519 	  /* Pop the error token.  */
1520           YYPOPSTACK;
1521 	  /* Pop the rest of the stack.  */
1522 	  while (yyss < yyssp)
1523 	    {
1524 	      YYDSYMPRINTF ("Error: popping", yystos[*yyssp], yyvsp, yylsp);
1525 	      yydestruct (yystos[*yyssp], yyvsp);
1526 	      YYPOPSTACK;
1527 	    }
1528 	  YYABORT;
1529         }
1530 
1531       YYDSYMPRINTF ("Error: discarding", yytoken, &yylval, &yylloc);
1532       yydestruct (yytoken, &yylval);
1533       yychar = YYEMPTY;
1534 
1535     }
1536 
1537   /* Else will try to reuse lookahead token after shifting the error
1538      token.  */
1539   goto yyerrlab2;
1540 
1541 
1542 /*----------------------------------------------------.
1543 | yyerrlab1 -- error raised explicitly by an action.  |
1544 `----------------------------------------------------*/
1545 yyerrlab1:
1546 
1547   /* Suppress GCC warning that yyerrlab1 is unused when no action
1548      invokes YYERROR.  */
1549 #if defined (__GNUC_MINOR__) && 2093 <= (__GNUC__ * 1000 + __GNUC_MINOR__)
1550 //  __attribute__ ((__unused__))
1551 #endif
1552 
1553 
1554   goto yyerrlab2;
1555 
1556 
1557 /*---------------------------------------------------------------.
1558 | yyerrlab2 -- pop states until the error token can be shifted.  |
1559 `---------------------------------------------------------------*/
1560 yyerrlab2:
1561   yyerrstatus = 3;	/* Each real token shifted decrements this.  */
1562 
1563   for (;;)
1564     {
1565       yyn = yypact[yystate];
1566       if (yyn != YYPACT_NINF)
1567 	{
1568 	  yyn += YYTERROR;
1569 	  if (0 <= yyn && yyn <= YYLAST && yycheck[yyn] == YYTERROR)
1570 	    {
1571 	      yyn = yytable[yyn];
1572 	      if (0 < yyn)
1573 		break;
1574 	    }
1575 	}
1576 
1577       /* Pop the current state because it cannot handle the error token.  */
1578       if (yyssp == yyss)
1579 	YYABORT;
1580 
1581       YYDSYMPRINTF ("Error: popping", yystos[*yyssp], yyvsp, yylsp);
1582       yydestruct (yystos[yystate], yyvsp);
1583       yyvsp--;
1584       yystate = *--yyssp;
1585 
1586       YY_STACK_PRINT (yyss, yyssp);
1587     }
1588 
1589   if (yyn == YYFINAL)
1590     YYACCEPT;
1591 
1592   YYDPRINTF ((stderr, "Shifting error token, "));
1593 
1594   *++yyvsp = yylval;
1595 
1596 
1597   yystate = yyn;
1598   goto yynewstate;
1599 
1600 
1601 /*-------------------------------------.
1602 | yyacceptlab -- YYACCEPT comes here.  |
1603 `-------------------------------------*/
1604 yyacceptlab:
1605   yyresult = 0;
1606   goto yyreturn;
1607 
1608 /*-----------------------------------.
1609 | yyabortlab -- YYABORT comes here.  |
1610 `-----------------------------------*/
1611 yyabortlab:
1612   yyresult = 1;
1613   goto yyreturn;
1614 
1615 #ifndef yyoverflow
1616 /*----------------------------------------------.
1617 | yyoverflowlab -- parser overflow comes here.  |
1618 `----------------------------------------------*/
1619 yyoverflowlab:
1620   yyerror (pParser, "parser stack overflow");
1621   yyresult = 2;
1622   /* Fall through.  */
1623 #endif
1624 
1625 yyreturn:
1626 #ifndef yyoverflow
1627   if (yyss != yyssa)
1628     YYSTACK_FREE (yyss);
1629 #endif
1630   return yyresult;
1631 }
1632 
1633 
1634 
1635 
1636 
1637