00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029
00030
00031
00032
00033
00034
00035
00036 #define yylex coco_api_internallex
00037
00038 #include "dbcompare_expression_parser.hh"
00039
00040
00041 #line 74 "dbcompare_expression_parser.y"
00042
00043 #include "dbcompare_expression_scanner.hh"
00044 #undef yylex
00045 #define yylex scanner.yylex
00046
00047 namespace coco_api_internal {
00048 using namespace coco;
00049
00050 void dbcompare_expression_parser::error(const location_type& l, const std::string& m)
00051 {
00052 if (errormsg.empty())
00053 errormsg = m;
00054 }
00055
00056 static inline dbc_method dbc_method_to_abs(dbc_method orig)
00057 {
00058 return static_cast<dbc_method>(static_cast<int>(orig) + (DB_COMPARE_CMP_ABSEQ - DB_COMPARE_CMP_EQ));
00059 }
00060 }
00061
00062
00063
00064 #line 65 "dbcompare_expression_parser.cc"
00065
00066 #ifndef YY_
00067 # if YYENABLE_NLS
00068 # if ENABLE_NLS
00069 # include <libintl.h>
00070 # define YY_(msgid) dgettext ("bison-runtime", msgid)
00071 # endif
00072 # endif
00073 # ifndef YY_
00074 # define YY_(msgid) msgid
00075 # endif
00076 #endif
00077
00078
00079 #define YYUSE(e) ((void) (e))
00080
00081
00082 # define YYCDEBUG \
00083 for (bool yydebugcond_ = yydebug_; yydebugcond_; yydebugcond_ = false) \
00084 (*yycdebug_)
00085
00086
00087 #if YYDEBUG
00088
00089 # define YY_SYMBOL_PRINT(Title, Type, Value, Location) \
00090 do { \
00091 if (yydebug_) \
00092 { \
00093 *yycdebug_ << Title << ' '; \
00094 yy_symbol_print_ ((Type), (Value), (Location)); \
00095 *yycdebug_ << std::endl; \
00096 } \
00097 } while (false)
00098
00099 # define YY_REDUCE_PRINT(Rule) \
00100 do { \
00101 if (yydebug_) \
00102 yy_reduce_print_ (Rule); \
00103 } while (false)
00104
00105 # define YY_STACK_PRINT() \
00106 do { \
00107 if (yydebug_) \
00108 yystack_print_ (); \
00109 } while (false)
00110
00111 #else
00112
00113 # define YY_SYMBOL_PRINT(Title, Type, Value, Location)
00114 # define YY_REDUCE_PRINT(Rule)
00115 # define YY_STACK_PRINT()
00116
00117 #endif
00118
00119 #define YYACCEPT goto yyacceptlab
00120 #define YYABORT goto yyabortlab
00121 #define YYERROR goto yyerrorlab
00122
00123 namespace coco_api_internal
00124 {
00125 #if YYERROR_VERBOSE
00126
00127
00128
00129
00130
00131
00132 std::string
00133 dbcompare_expression_parser::yytnamerr_ (const char *yystr)
00134 {
00135 if (*yystr == '"')
00136 {
00137 std::string yyr = "";
00138 char const *yyp = yystr;
00139
00140 for (;;)
00141 switch (*++yyp)
00142 {
00143 case '\'':
00144 case ',':
00145 goto do_not_strip_quotes;
00146
00147 case '\\':
00148 if (*++yyp != '\\')
00149 goto do_not_strip_quotes;
00150
00151 default:
00152 yyr += *yyp;
00153 break;
00154
00155 case '"':
00156 return yyr;
00157 }
00158 do_not_strip_quotes: ;
00159 }
00160
00161 return yystr;
00162 }
00163
00164 #endif
00165
00167 dbcompare_expression_parser::dbcompare_expression_parser (coco_api_internal::dbcompare_expression_scanner &scanner_yyarg, std::map<int,std::triple<std::string, coco::dbc_method, coco::basic_alltype> > &cols_yyarg, std::vector<std::vector<int> > &expr_yyarg, int &map_index_yyarg, std::string &errormsg_yyarg)
00168 : yydebug_ (false),
00169 yycdebug_ (&std::cerr),
00170 scanner (scanner_yyarg),
00171 cols (cols_yyarg),
00172 expr (expr_yyarg),
00173 map_index (map_index_yyarg),
00174 errormsg (errormsg_yyarg)
00175 {
00176 }
00177
00178 dbcompare_expression_parser::~dbcompare_expression_parser ()
00179 {
00180 }
00181
00182 #if YYDEBUG
00183
00184
00185
00186
00187 inline void
00188 dbcompare_expression_parser::yy_symbol_value_print_ (int yytype,
00189 const semantic_type* yyvaluep, const location_type* yylocationp)
00190 {
00191 YYUSE (yylocationp);
00192 YYUSE (yyvaluep);
00193 switch (yytype)
00194 {
00195 default:
00196 break;
00197 }
00198 }
00199
00200
00201 void
00202 dbcompare_expression_parser::yy_symbol_print_ (int yytype,
00203 const semantic_type* yyvaluep, const location_type* yylocationp)
00204 {
00205 *yycdebug_ << (yytype < yyntokens_ ? "token" : "nterm")
00206 << ' ' << yytname_[yytype] << " ("
00207 << *yylocationp << ": ";
00208 yy_symbol_value_print_ (yytype, yyvaluep, yylocationp);
00209 *yycdebug_ << ')';
00210 }
00211 #endif
00212
00213 void
00214 dbcompare_expression_parser::yydestruct_ (const char* yymsg,
00215 int yytype, semantic_type* yyvaluep, location_type* yylocationp)
00216 {
00217 YYUSE (yylocationp);
00218 YYUSE (yymsg);
00219 YYUSE (yyvaluep);
00220
00221 YY_SYMBOL_PRINT (yymsg, yytype, yyvaluep, yylocationp);
00222
00223 switch (yytype)
00224 {
00225 case 14:
00226 #line 70 "dbcompare_expression_parser.y"
00227 { delete (yyvaluep->varname); };
00228 #line 229 "dbcompare_expression_parser.cc"
00229 break;
00230 case 18:
00231 #line 70 "dbcompare_expression_parser.y"
00232 { delete (yyvaluep->and_expr); };
00233 #line 234 "dbcompare_expression_parser.cc"
00234 break;
00235
00236 default:
00237 break;
00238 }
00239 }
00240
00241 void
00242 dbcompare_expression_parser::yypop_ (unsigned int n)
00243 {
00244 yystate_stack_.pop (n);
00245 yysemantic_stack_.pop (n);
00246 yylocation_stack_.pop (n);
00247 }
00248
00249 std::ostream&
00250 dbcompare_expression_parser::debug_stream () const
00251 {
00252 return *yycdebug_;
00253 }
00254
00255 void
00256 dbcompare_expression_parser::set_debug_stream (std::ostream& o)
00257 {
00258 yycdebug_ = &o;
00259 }
00260
00261
00262 dbcompare_expression_parser::debug_level_type
00263 dbcompare_expression_parser::debug_level () const
00264 {
00265 return yydebug_;
00266 }
00267
00268 void
00269 dbcompare_expression_parser::set_debug_level (debug_level_type l)
00270 {
00271 yydebug_ = l;
00272 }
00273
00274
00275 int
00276 dbcompare_expression_parser::parse ()
00277 {
00279 int yychar = yyempty_;
00280 int yytoken = 0;
00281
00282
00283 int yyn;
00284 int yylen = 0;
00285 int yystate = 0;
00286
00287
00288 int yynerrs_ = 0;
00289 int yyerrstatus_ = 0;
00290
00292 semantic_type yylval;
00294 location_type yylloc;
00296 location yyerror_range[2];
00297
00299 semantic_type yyval;
00301 location_type yyloc;
00302
00303 int yyresult;
00304
00305 YYCDEBUG << "Starting parse" << std::endl;
00306
00307
00308
00309
00310
00311
00312 yystate_stack_ = state_stack_type (0);
00313 yysemantic_stack_ = semantic_stack_type (0);
00314 yylocation_stack_ = location_stack_type (0);
00315 yysemantic_stack_.push (yylval);
00316 yylocation_stack_.push (yylloc);
00317
00318
00319 yynewstate:
00320 yystate_stack_.push (yystate);
00321 YYCDEBUG << "Entering state " << yystate << std::endl;
00322 goto yybackup;
00323
00324
00325 yybackup:
00326
00327
00328 yyn = yypact_[yystate];
00329 if (yyn == yypact_ninf_)
00330 goto yydefault;
00331
00332
00333 if (yychar == yyempty_)
00334 {
00335 YYCDEBUG << "Reading a token: ";
00336 yychar = yylex (&yylval);
00337 }
00338
00339
00340
00341 if (yychar <= yyeof_)
00342 {
00343 yychar = yytoken = yyeof_;
00344 YYCDEBUG << "Now at end of input." << std::endl;
00345 }
00346 else
00347 {
00348 yytoken = yytranslate_ (yychar);
00349 YY_SYMBOL_PRINT ("Next token is", yytoken, &yylval, &yylloc);
00350 }
00351
00352
00353
00354 yyn += yytoken;
00355 if (yyn < 0 || yylast_ < yyn || yycheck_[yyn] != yytoken)
00356 goto yydefault;
00357
00358
00359 yyn = yytable_[yyn];
00360 if (yyn <= 0)
00361 {
00362 if (yyn == 0 || yyn == yytable_ninf_)
00363 goto yyerrlab;
00364 yyn = -yyn;
00365 goto yyreduce;
00366 }
00367
00368
00369 if (yyn == yyfinal_)
00370 goto yyacceptlab;
00371
00372
00373 YY_SYMBOL_PRINT ("Shifting", yytoken, &yylval, &yylloc);
00374
00375
00376 if (yychar != yyeof_)
00377 yychar = yyempty_;
00378
00379 yysemantic_stack_.push (yylval);
00380 yylocation_stack_.push (yylloc);
00381
00382
00383
00384 if (yyerrstatus_)
00385 --yyerrstatus_;
00386
00387 yystate = yyn;
00388 goto yynewstate;
00389
00390
00391
00392
00393 yydefault:
00394 yyn = yydefact_[yystate];
00395 if (yyn == 0)
00396 goto yyerrlab;
00397 goto yyreduce;
00398
00399
00400
00401
00402 yyreduce:
00403 yylen = yyr2_[yyn];
00404
00405
00406
00407
00408
00409
00410 if (yylen)
00411 yyval = yysemantic_stack_[yylen - 1];
00412 else
00413 yyval = yysemantic_stack_[0];
00414
00415 {
00416 slice<location_type, location_stack_type> slice (yylocation_stack_, yylen);
00417 YYLLOC_DEFAULT (yyloc, slice, yylen);
00418 }
00419 YY_REDUCE_PRINT (yyn);
00420 switch (yyn)
00421 {
00422 case 2:
00423 #line 97 "dbcompare_expression_parser.y"
00424 {
00425 expr.push_back(*(yysemantic_stack_[(3) - (3)].and_expr));
00426 ;}
00427 break;
00428
00429 case 3:
00430 #line 100 "dbcompare_expression_parser.y"
00431 {
00432 expr.push_back(*(yysemantic_stack_[(1) - (1)].and_expr));
00433 ;}
00434 break;
00435
00436 case 4:
00437 #line 105 "dbcompare_expression_parser.y"
00438 {
00439 (yyval.and_expr) = new std::vector<int>;
00440 *(yyval.and_expr) = *(yysemantic_stack_[(3) - (1)].and_expr);
00441 (yyval.and_expr)->push_back((yysemantic_stack_[(3) - (3)].cmp_expr));
00442 ;}
00443 break;
00444
00445 case 5:
00446 #line 110 "dbcompare_expression_parser.y"
00447 {
00448 (yyval.and_expr) = new std::vector<int>;
00449 (yyval.and_expr)->push_back((yysemantic_stack_[(1) - (1)].cmp_expr));
00450 ;}
00451 break;
00452
00453 case 6:
00454 #line 116 "dbcompare_expression_parser.y"
00455 {
00456 (yyval.cmp_expr) = map_index;
00457 cols[map_index++] = std::triple<std::string, dbc_method, basic_alltype>(*(yysemantic_stack_[(3) - (1)].varname), (yysemantic_stack_[(3) - (2)].comparison), (yysemantic_stack_[(3) - (3)].value));
00458 ;}
00459 break;
00460
00461 case 7:
00462 #line 120 "dbcompare_expression_parser.y"
00463 {
00464 (yyval.cmp_expr) = -map_index;
00465 cols[map_index++] = std::triple<std::string, dbc_method, basic_alltype>(*(yysemantic_stack_[(4) - (2)].varname), (yysemantic_stack_[(4) - (3)].comparison), (yysemantic_stack_[(4) - (4)].value));
00466 ;}
00467 break;
00468
00469 case 8:
00470 #line 124 "dbcompare_expression_parser.y"
00471 {
00472 (yyval.cmp_expr) = map_index;
00473 cols[map_index++] = std::triple<std::string, dbc_method, basic_alltype>(*(yysemantic_stack_[(5) - (2)].varname), dbc_method_to_abs((yysemantic_stack_[(5) - (4)].comparison)), (yysemantic_stack_[(5) - (5)].value));
00474 ;}
00475 break;
00476
00477 case 9:
00478 #line 128 "dbcompare_expression_parser.y"
00479 {
00480 (yyval.cmp_expr) = -map_index;
00481 cols[map_index++] = std::triple<std::string, dbc_method, basic_alltype>(*(yysemantic_stack_[(6) - (3)].varname), dbc_method_to_abs((yysemantic_stack_[(6) - (5)].comparison)), (yysemantic_stack_[(6) - (6)].value));
00482 ;}
00483 break;
00484
00485 case 10:
00486 #line 134 "dbcompare_expression_parser.y"
00487 { (yyval.comparison) = dbc_cmp_eq; ;}
00488 break;
00489
00490 case 11:
00491 #line 135 "dbcompare_expression_parser.y"
00492 { (yyval.comparison) = dbc_cmp_ne; ;}
00493 break;
00494
00495 case 12:
00496 #line 136 "dbcompare_expression_parser.y"
00497 { (yyval.comparison) = dbc_cmp_gt; ;}
00498 break;
00499
00500 case 13:
00501 #line 137 "dbcompare_expression_parser.y"
00502 { (yyval.comparison) = dbc_cmp_ge; ;}
00503 break;
00504
00505 case 14:
00506 #line 138 "dbcompare_expression_parser.y"
00507 { (yyval.comparison) = dbc_cmp_lt; ;}
00508 break;
00509
00510 case 15:
00511 #line 139 "dbcompare_expression_parser.y"
00512 { (yyval.comparison) = dbc_cmp_le; ;}
00513 break;
00514
00515
00516
00517 #line 518 "dbcompare_expression_parser.cc"
00518 default: break;
00519 }
00520 YY_SYMBOL_PRINT ("-> $$ =", yyr1_[yyn], &yyval, &yyloc);
00521
00522 yypop_ (yylen);
00523 yylen = 0;
00524 YY_STACK_PRINT ();
00525
00526 yysemantic_stack_.push (yyval);
00527 yylocation_stack_.push (yyloc);
00528
00529
00530 yyn = yyr1_[yyn];
00531 yystate = yypgoto_[yyn - yyntokens_] + yystate_stack_[0];
00532 if (0 <= yystate && yystate <= yylast_
00533 && yycheck_[yystate] == yystate_stack_[0])
00534 yystate = yytable_[yystate];
00535 else
00536 yystate = yydefgoto_[yyn - yyntokens_];
00537 goto yynewstate;
00538
00539
00540
00541
00542 yyerrlab:
00543
00544 if (!yyerrstatus_)
00545 {
00546 ++yynerrs_;
00547 error (yylloc, yysyntax_error_ (yystate));
00548 }
00549
00550 yyerror_range[0] = yylloc;
00551 if (yyerrstatus_ == 3)
00552 {
00553
00554
00555
00556 if (yychar <= yyeof_)
00557 {
00558
00559 if (yychar == yyeof_)
00560 YYABORT;
00561 }
00562 else
00563 {
00564 yydestruct_ ("Error: discarding", yytoken, &yylval, &yylloc);
00565 yychar = yyempty_;
00566 }
00567 }
00568
00569
00570
00571 goto yyerrlab1;
00572
00573
00574
00575
00576
00577 yyerrorlab:
00578
00579
00580
00581
00582 if (false)
00583 goto yyerrorlab;
00584
00585 yyerror_range[0] = yylocation_stack_[yylen - 1];
00586
00587
00588 yypop_ (yylen);
00589 yylen = 0;
00590 yystate = yystate_stack_[0];
00591 goto yyerrlab1;
00592
00593
00594
00595
00596 yyerrlab1:
00597 yyerrstatus_ = 3;
00598
00599 for (;;)
00600 {
00601 yyn = yypact_[yystate];
00602 if (yyn != yypact_ninf_)
00603 {
00604 yyn += yyterror_;
00605 if (0 <= yyn && yyn <= yylast_ && yycheck_[yyn] == yyterror_)
00606 {
00607 yyn = yytable_[yyn];
00608 if (0 < yyn)
00609 break;
00610 }
00611 }
00612
00613
00614 if (yystate_stack_.height () == 1)
00615 YYABORT;
00616
00617 yyerror_range[0] = yylocation_stack_[0];
00618 yydestruct_ ("Error: popping",
00619 yystos_[yystate],
00620 &yysemantic_stack_[0], &yylocation_stack_[0]);
00621 yypop_ ();
00622 yystate = yystate_stack_[0];
00623 YY_STACK_PRINT ();
00624 }
00625
00626 if (yyn == yyfinal_)
00627 goto yyacceptlab;
00628
00629 yyerror_range[1] = yylloc;
00630
00631
00632 YYLLOC_DEFAULT (yyloc, (yyerror_range - 1), 2);
00633 yysemantic_stack_.push (yylval);
00634 yylocation_stack_.push (yyloc);
00635
00636
00637 YY_SYMBOL_PRINT ("Shifting", yystos_[yyn],
00638 &yysemantic_stack_[0], &yylocation_stack_[0]);
00639
00640 yystate = yyn;
00641 goto yynewstate;
00642
00643
00644 yyacceptlab:
00645 yyresult = 0;
00646 goto yyreturn;
00647
00648
00649 yyabortlab:
00650 yyresult = 1;
00651 goto yyreturn;
00652
00653 yyreturn:
00654 if (yychar != yyeof_ && yychar != yyempty_)
00655 yydestruct_ ("Cleanup: discarding lookahead", yytoken, &yylval, &yylloc);
00656
00657
00658
00659 yypop_ (yylen);
00660 while (yystate_stack_.height () != 1)
00661 {
00662 yydestruct_ ("Cleanup: popping",
00663 yystos_[yystate_stack_[0]],
00664 &yysemantic_stack_[0],
00665 &yylocation_stack_[0]);
00666 yypop_ ();
00667 }
00668
00669 return yyresult;
00670 }
00671
00672
00673 std::string
00674 dbcompare_expression_parser::yysyntax_error_ (int yystate)
00675 {
00676 std::string res;
00677 YYUSE (yystate);
00678 #if YYERROR_VERBOSE
00679 int yyn = yypact_[yystate];
00680 if (yypact_ninf_ < yyn && yyn <= yylast_)
00681 {
00682
00683
00684 int yyxbegin = yyn < 0 ? -yyn : 0;
00685
00686
00687 int yychecklim = yylast_ - yyn + 1;
00688 int yyxend = yychecklim < yyntokens_ ? yychecklim : yyntokens_;
00689 int count = 0;
00690 for (int x = yyxbegin; x < yyxend; ++x)
00691 if (yycheck_[x + yyn] == x && x != yyterror_)
00692 ++count;
00693
00694
00695
00696
00697
00698
00699
00700
00701
00702 res = "syntax error, unexpected ";
00703 res += yytnamerr_ (yytname_[tok]);
00704 if (count < 5)
00705 {
00706 count = 0;
00707 for (int x = yyxbegin; x < yyxend; ++x)
00708 if (yycheck_[x + yyn] == x && x != yyterror_)
00709 {
00710 res += (!count++) ? ", expecting " : " or ";
00711 res += yytnamerr_ (yytname_[x]);
00712 }
00713 }
00714 }
00715 else
00716 #endif
00717 res = YY_("syntax error");
00718 return res;
00719 }
00720
00721
00722
00723
00724 const signed char dbcompare_expression_parser::yypact_ninf_ = -9;
00725 const signed char
00726 dbcompare_expression_parser::yypact_[] =
00727 {
00728 -2, 3, -6, -1, 1, 4, -9, 2, -1, 7,
00729 -9, -9, -9, -9, -9, -9, 5, -9, -2, -2,
00730 9, 8, -1, -9, 4, -9, -1, -9, 10, 11,
00731 -9, -9
00732 };
00733
00734
00735
00736
00737 const unsigned char
00738 dbcompare_expression_parser::yydefact_[] =
00739 {
00740 0, 0, 0, 0, 0, 3, 5, 0, 0, 0,
00741 10, 11, 13, 15, 12, 14, 0, 1, 0, 0,
00742 0, 0, 0, 6, 2, 4, 0, 7, 0, 0,
00743 8, 9
00744 };
00745
00746
00747 const signed char
00748 dbcompare_expression_parser::yypgoto_[] =
00749 {
00750 -9, -9, 6, 12, -8
00751 };
00752
00753
00754 const signed char
00755 dbcompare_expression_parser::yydefgoto_[] =
00756 {
00757 -1, 4, 5, 6, 16
00758 };
00759
00760
00761
00762
00763 const signed char dbcompare_expression_parser::yytable_ninf_ = -1;
00764 const unsigned char
00765 dbcompare_expression_parser::yytable_[] =
00766 {
00767 21, 17, 10, 11, 12, 13, 14, 15, 9, 1,
00768 2, 18, 3, 19, 28, 7, 20, 8, 29, 22,
00769 23, 26, 0, 27, 24, 30, 31, 0, 0, 0,
00770 0, 25
00771 };
00772
00773
00774 const signed char
00775 dbcompare_expression_parser::yycheck_[] =
00776 {
00777 8, 0, 3, 4, 5, 6, 7, 8, 14, 11,
00778 12, 10, 14, 9, 22, 12, 14, 14, 26, 12,
00779 15, 12, -1, 15, 18, 15, 15, -1, -1, -1,
00780 -1, 19
00781 };
00782
00783
00784
00785 const unsigned char
00786 dbcompare_expression_parser::yystos_[] =
00787 {
00788 0, 11, 12, 14, 17, 18, 19, 12, 14, 14,
00789 3, 4, 5, 6, 7, 8, 20, 0, 10, 9,
00790 14, 20, 12, 15, 18, 19, 12, 15, 20, 20,
00791 15, 15
00792 };
00793
00794 #if YYDEBUG
00795
00796
00797 const unsigned short int
00798 dbcompare_expression_parser::yytoken_number_[] =
00799 {
00800 0, 256, 257, 258, 259, 260, 261, 262, 263, 264,
00801 265, 266, 267, 268, 269, 270
00802 };
00803 #endif
00804
00805
00806 const unsigned char
00807 dbcompare_expression_parser::yyr1_[] =
00808 {
00809 0, 16, 17, 17, 18, 18, 19, 19, 19, 19,
00810 20, 20, 20, 20, 20, 20
00811 };
00812
00813
00814 const unsigned char
00815 dbcompare_expression_parser::yyr2_[] =
00816 {
00817 0, 2, 3, 1, 3, 1, 3, 4, 5, 6,
00818 1, 1, 1, 1, 1, 1
00819 };
00820
00821 #if YYDEBUG || YYERROR_VERBOSE || YYTOKEN_TABLE
00822
00823
00824 const char*
00825 const dbcompare_expression_parser::yytname_[] =
00826 {
00827 "$end", "error", "$undefined", "OP_EQ", "OP_NE", "OP_GE", "OP_LE",
00828 "OP_GT", "OP_LT", "OP_AND", "OP_OR", "OP_NOT", "OP_ABS", "SCAN_ERROR",
00829 "VARNAME", "FLOAT", "$accept", "expression", "and_expr", "cmp_expr",
00830 "comparison", 0
00831 };
00832 #endif
00833
00834 #if YYDEBUG
00835
00836 const dbcompare_expression_parser::rhs_number_type
00837 dbcompare_expression_parser::yyrhs_[] =
00838 {
00839 17, 0, -1, 17, 10, 18, -1, 18, -1, 18,
00840 9, 19, -1, 19, -1, 14, 20, 15, -1, 11,
00841 14, 20, 15, -1, 12, 14, 12, 20, 15, -1,
00842 11, 12, 14, 12, 20, 15, -1, 3, -1, 4,
00843 -1, 7, -1, 5, -1, 8, -1, 6, -1
00844 };
00845
00846
00847
00848 const unsigned char
00849 dbcompare_expression_parser::yyprhs_[] =
00850 {
00851 0, 0, 3, 7, 9, 13, 15, 19, 24, 30,
00852 37, 39, 41, 43, 45, 47
00853 };
00854
00855
00856 const unsigned char
00857 dbcompare_expression_parser::yyrline_[] =
00858 {
00859 0, 97, 97, 100, 105, 110, 116, 120, 124, 128,
00860 134, 135, 136, 137, 138, 139
00861 };
00862
00863
00864 void
00865 dbcompare_expression_parser::yystack_print_ ()
00866 {
00867 *yycdebug_ << "Stack now";
00868 for (state_stack_type::const_iterator i = yystate_stack_.begin ();
00869 i != yystate_stack_.end (); ++i)
00870 *yycdebug_ << ' ' << *i;
00871 *yycdebug_ << std::endl;
00872 }
00873
00874
00875 void
00876 dbcompare_expression_parser::yy_reduce_print_ (int yyrule)
00877 {
00878 unsigned int yylno = yyrline_[yyrule];
00879 int yynrhs = yyr2_[yyrule];
00880
00881 *yycdebug_ << "Reducing stack by rule " << yyrule - 1
00882 << " (line " << yylno << "), ";
00883
00884 for (int yyi = 0; yyi < yynrhs; yyi++)
00885 YY_SYMBOL_PRINT (" $" << yyi + 1 << " =",
00886 yyrhs_[yyprhs_[yyrule] + yyi],
00887 &(yysemantic_stack_[(yynrhs) - (yyi + 1)]),
00888 &(yylocation_stack_[(yynrhs) - (yyi + 1)]));
00889 }
00890 #endif // YYDEBUG
00891
00892
00893 dbcompare_expression_parser::token_number_type
00894 dbcompare_expression_parser::yytranslate_ (int t)
00895 {
00896 static
00897 const token_number_type
00898 translate_table[] =
00899 {
00900 0, 2, 2, 2, 2, 2, 2, 2, 2, 2,
00901 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
00902 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
00903 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
00904 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
00905 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
00906 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
00907 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
00908 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
00909 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
00910 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
00911 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
00912 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
00913 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
00914 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
00915 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
00916 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
00917 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
00918 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
00919 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
00920 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
00921 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
00922 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
00923 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
00924 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
00925 2, 2, 2, 2, 2, 2, 1, 2, 3, 4,
00926 5, 6, 7, 8, 9, 10, 11, 12, 13, 14,
00927 15
00928 };
00929 if ((unsigned int) t <= yyuser_token_number_max_)
00930 return translate_table[t];
00931 else
00932 return yyundef_token_;
00933 }
00934
00935 const int dbcompare_expression_parser::yyeof_ = 0;
00936 const int dbcompare_expression_parser::yylast_ = 31;
00937 const int dbcompare_expression_parser::yynnts_ = 5;
00938 const int dbcompare_expression_parser::yyempty_ = -2;
00939 const int dbcompare_expression_parser::yyfinal_ = 17;
00940 const int dbcompare_expression_parser::yyterror_ = 1;
00941 const int dbcompare_expression_parser::yyerrcode_ = 256;
00942 const int dbcompare_expression_parser::yyntokens_ = 16;
00943
00944 const unsigned int dbcompare_expression_parser::yyuser_token_number_max_ = 270;
00945 const dbcompare_expression_parser::token_number_type dbcompare_expression_parser::yyundef_token_ = 2;
00946
00947 }
00948
00949