52#if defined(__GNUC__) || defined(__clang__)
53#pragma GCC diagnostic ignored "-Wunused-but-set-variable"
60# if defined YYENABLE_NLS && YYENABLE_NLS
63# define YY_(msgid) dgettext ("bison-runtime", msgid)
67# define YY_(msgid) msgid
74# if defined __GNUC__ && !defined __EXCEPTIONS
75# define YY_EXCEPTIONS 0
77# define YY_EXCEPTIONS 1
81#define YYRHSLOC(Rhs, K) ((Rhs)[K].location)
86# ifndef YYLLOC_DEFAULT
87# define YYLLOC_DEFAULT(Current, Rhs, N) \
91 (Current).begin = YYRHSLOC (Rhs, 1).begin; \
92 (Current).end = YYRHSLOC (Rhs, N).end; \
96 (Current).begin = (Current).end = YYRHSLOC (Rhs, 0).end; \
106# define YYCDEBUG if (yydebug_) (*yycdebug_)
108# define YY_SYMBOL_PRINT(Title, Symbol) \
112 *yycdebug_ << Title << ' '; \
113 yy_print_ (*yycdebug_, Symbol); \
114 *yycdebug_ << '\n'; \
118# define YY_REDUCE_PRINT(Rule) \
121 yy_reduce_print_ (Rule); \
124# define YY_STACK_PRINT() \
127 yy_stack_print_ (); \
132# define YYCDEBUG if (false) std::cerr
133# define YY_SYMBOL_PRINT(Title, Symbol) YY_USE (Symbol)
134# define YY_REDUCE_PRINT(Rule) static_cast<void> (0)
135# define YY_STACK_PRINT() static_cast<void> (0)
139#define yyerrok (yyerrstatus_ = 0)
140#define yyclearin (yyla.clear ())
142#define YYACCEPT goto yyacceptlab
143#define YYABORT goto yyabortlab
144#define YYERROR goto yyerrorlab
145#define YYRECOVERING() (!!yyerrstatus_)
148namespace isc {
namespace eval {
155 yycdebug_ (&std::cerr),
176 : state (empty_state)
179 EvalParser::by_state::by_state (
const by_state& that)
YY_NOEXCEPT
190 EvalParser::by_state::move (by_state& that)
196 EvalParser::by_state::by_state (state_type s)
YY_NOEXCEPT
203 if (state == empty_state)
209 EvalParser::stack_symbol_type::stack_symbol_type ()
212 EvalParser::stack_symbol_type::stack_symbol_type (
YY_RVREF (stack_symbol_type) that)
215 switch (that.kind ())
217 case symbol_kind::S_option_repr_type:
218 value.YY_MOVE_OR_COPY< TokenOption::RepresentationType > (YY_MOVE (that.value));
221 case symbol_kind::S_pkt4_field:
222 value.YY_MOVE_OR_COPY< TokenPkt4::FieldType > (YY_MOVE (that.value));
225 case symbol_kind::S_pkt6_field:
226 value.YY_MOVE_OR_COPY< TokenPkt6::FieldType > (YY_MOVE (that.value));
229 case symbol_kind::S_pkt_metadata:
230 value.YY_MOVE_OR_COPY< TokenPkt::MetadataType > (YY_MOVE (that.value));
233 case symbol_kind::S_relay6_field:
234 value.YY_MOVE_OR_COPY< TokenRelay6Field::FieldType > (YY_MOVE (that.value));
237 case symbol_kind::S_nest_level:
238 value.YY_MOVE_OR_COPY< int8_t > (YY_MOVE (that.value));
241 case symbol_kind::S_relay6_option_chain:
242 value.YY_MOVE_OR_COPY< std::pair<int8_t, std::vector<uint16_t>> > (YY_MOVE (that.value));
245 case symbol_kind::S_vendor_option_chain:
246 value.YY_MOVE_OR_COPY< std::pair<uint32_t, std::vector<uint16_t>> > (YY_MOVE (that.value));
249 case symbol_kind::S_STRING:
250 case symbol_kind::S_INTEGER:
251 case symbol_kind::S_HEXSTRING:
252 case symbol_kind::S_OPTION_NAME:
253 case symbol_kind::S_IP_ADDRESS:
254 value.YY_MOVE_OR_COPY< std::string > (YY_MOVE (that.value));
257 case symbol_kind::S_option_chain:
258 case symbol_kind::S_relay4_option_chain:
259 value.YY_MOVE_OR_COPY< std::vector<uint16_t> > (YY_MOVE (that.value));
262 case symbol_kind::S_option_code:
263 case symbol_kind::S_sub_option_code:
264 value.YY_MOVE_OR_COPY< uint16_t > (YY_MOVE (that.value));
267 case symbol_kind::S_integer_expr:
268 case symbol_kind::S_enterprise_id:
269 value.YY_MOVE_OR_COPY< uint32_t > (YY_MOVE (that.value));
278 that.state = empty_state;
283 : super_type (s,
YY_MOVE (that.location))
285 switch (that.kind ())
287 case symbol_kind::S_option_repr_type:
288 value.move< TokenOption::RepresentationType > (YY_MOVE (that.value));
291 case symbol_kind::S_pkt4_field:
292 value.move< TokenPkt4::FieldType > (YY_MOVE (that.value));
295 case symbol_kind::S_pkt6_field:
296 value.move< TokenPkt6::FieldType > (YY_MOVE (that.value));
299 case symbol_kind::S_pkt_metadata:
300 value.move< TokenPkt::MetadataType > (YY_MOVE (that.value));
303 case symbol_kind::S_relay6_field:
304 value.move< TokenRelay6Field::FieldType > (YY_MOVE (that.value));
307 case symbol_kind::S_nest_level:
308 value.move< int8_t > (YY_MOVE (that.value));
311 case symbol_kind::S_relay6_option_chain:
312 value.move< std::pair<int8_t, std::vector<uint16_t>> > (YY_MOVE (that.value));
315 case symbol_kind::S_vendor_option_chain:
316 value.move< std::pair<uint32_t, std::vector<uint16_t>> > (YY_MOVE (that.value));
319 case symbol_kind::S_STRING:
320 case symbol_kind::S_INTEGER:
321 case symbol_kind::S_HEXSTRING:
322 case symbol_kind::S_OPTION_NAME:
323 case symbol_kind::S_IP_ADDRESS:
324 value.move< std::string > (YY_MOVE (that.value));
327 case symbol_kind::S_option_chain:
328 case symbol_kind::S_relay4_option_chain:
329 value.move< std::vector<uint16_t> > (YY_MOVE (that.value));
332 case symbol_kind::S_option_code:
333 case symbol_kind::S_sub_option_code:
334 value.move< uint16_t > (YY_MOVE (that.value));
337 case symbol_kind::S_integer_expr:
338 case symbol_kind::S_enterprise_id:
339 value.move< uint32_t > (YY_MOVE (that.value));
350#if YY_CPLUSPLUS < 201103L
351 EvalParser::stack_symbol_type&
352 EvalParser::stack_symbol_type::operator= (
const stack_symbol_type& that)
355 switch (that.kind ())
378 value.copy< int8_t > (that.value);
382 value.copy< std::pair<int8_t, std::vector<uint16_t>> > (that.value);
386 value.copy< std::pair<uint32_t, std::vector<uint16_t>> > (that.value);
394 value.copy< std::string > (that.value);
399 value.copy< std::vector<uint16_t> > (that.value);
404 value.copy< uint16_t > (that.value);
409 value.copy< uint32_t > (that.value);
416 location = that.location;
420 EvalParser::stack_symbol_type&
421 EvalParser::stack_symbol_type::operator= (stack_symbol_type& that)
424 switch (that.kind ())
447 value.move< int8_t > (that.value);
451 value.move< std::pair<int8_t, std::vector<uint16_t>> > (that.value);
455 value.move< std::pair<uint32_t, std::vector<uint16_t>> > (that.value);
463 value.move< std::string > (that.value);
468 value.move< std::vector<uint16_t> > (that.value);
473 value.move< uint16_t > (that.value);
478 value.move< uint32_t > (that.value);
485 location = that.location;
487 that.state = empty_state;
492 template <
typename Base>
501 template <
typename Base>
505 std::ostream& yyoutput = yyo;
508 yyo <<
"empty symbol";
512 yyo << (yykind <
YYNTOKENS ?
"token" :
"nterm")
513 <<
' ' << yysym.name () <<
" ("
514 << yysym.location <<
": ";
519 { yyoutput << yysym.value.template as < std::string > (); }
525 { yyoutput << yysym.value.template as < std::string > (); }
531 { yyoutput << yysym.value.template as < std::string > (); }
537 { yyoutput << yysym.value.template as < std::string > (); }
543 { yyoutput << yysym.value.template as < std::string > (); }
550 for (
size_t i = 0; i < yysym.value.template as < std::vector<uint16_t> > ().size(); ++i) {
551 yyoutput << (i > 0 ?
", " :
"") << yysym.value.template as < std::vector<uint16_t> > ()[i];
560 for (
size_t i = 0; i < yysym.value.template as < std::vector<uint16_t> > ().size(); ++i) {
561 yyoutput << (i > 0 ?
", " :
"") << yysym.value.template as < std::vector<uint16_t> > ()[i];
570 yyoutput << yysym.value.template as < std::pair<int8_t, std::vector<uint16_t>> > ().first << std::endl;
571 for (
size_t i = 0; i < yysym.value.template as < std::pair<int8_t, std::vector<uint16_t>> > ().second.size(); ++i) {
572 yyoutput << (i > 0 ?
", " :
"") << yysym.value.template as < std::pair<int8_t, std::vector<uint16_t>> > ().second[i];
581 yyoutput << yysym.value.template as < std::pair<uint32_t, std::vector<uint16_t>> > ().first << std::endl;
582 for (
size_t i = 0; i < yysym.value.template as < std::pair<uint32_t, std::vector<uint16_t>> > ().second.size(); ++i) {
583 yyoutput << (i > 0 ?
", " :
"") << yysym.value.template as < std::pair<uint32_t, std::vector<uint16_t>> > ().second[i];
591 { yyoutput << yysym.value.template as < uint32_t > (); }
597 { yyoutput << yysym.value.template as < uint16_t > (); }
603 { yyoutput << yysym.value.template as < uint16_t > (); }
609 { yyoutput << yysym.value.template as < TokenOption::RepresentationType > (); }
615 { yyoutput << yysym.value.template as < int8_t > (); }
621 { yyoutput << yysym.value.template as < TokenPkt::MetadataType > (); }
627 { yyoutput << yysym.value.template as < uint32_t > (); }
633 { yyoutput << yysym.value.template as < TokenPkt4::FieldType > (); }
639 { yyoutput << yysym.value.template as < TokenPkt6::FieldType > (); }
645 { yyoutput << yysym.value.template as < TokenRelay6Field::FieldType > (); }
658 EvalParser::yypush_ (
const char* m,
YY_MOVE_REF (stack_symbol_type) sym)
668#if 201103L <= YY_CPLUSPLUS
669 yypush_ (m, stack_symbol_type (s, std::move (sym)));
671 stack_symbol_type ss (s, sym);
684 EvalParser::debug_stream ()
const
690 EvalParser::set_debug_stream (std::ostream& o)
696 EvalParser::debug_level_type
697 EvalParser::debug_level ()
const
703 EvalParser::set_debug_level (debug_level_type l)
709 EvalParser::state_type
710 EvalParser::yy_lr_goto_state_ (state_type yystate,
int yysym)
712 int yyr = yypgoto_[yysym -
YYNTOKENS] + yystate;
713 if (0 <= yyr && yyr <= yylast_ && yycheck_[yyr] == yystate)
714 return yytable_[yyr];
720 EvalParser::yy_pact_value_is_default_ (
int yyvalue)
YY_NOEXCEPT
722 return yyvalue == yypact_ninf_;
726 EvalParser::yy_table_value_is_error_ (
int yyvalue)
YY_NOEXCEPT
728 return yyvalue == yytable_ninf_;
746 int yyerrstatus_ = 0;
752 stack_symbol_type yyerror_range[3];
769 yypush_ (YY_NULLPTR, 0,
YY_MOVE (yyla));
775 YYCDEBUG <<
"Entering state " << int (yystack_[0].state) <<
'\n';
779 if (yystack_[0].state == yyfinal_)
790 yyn = yypact_[+yystack_[0].state];
791 if (yy_pact_value_is_default_ (yyn))
803 yyla.
move (yylookahead);
808 YYCDEBUG <<
"Caught exception: " << yyexc.what() <<
'\n';
829 if (yyn < 0 || yylast_ < yyn || yycheck_[yyn] != yyla.
kind ())
838 if (yy_table_value_is_error_ (yyn))
849 yypush_ (
"Shifting", state_type (yyn),
YY_MOVE (yyla));
857 yyn = yydefact_[+yystack_[0].state];
869 stack_symbol_type yylhs;
870 yylhs.state = yy_lr_goto_state_ (yystack_[yylen].state, yyr1_[yyn]);
901 yylhs.
value.
emplace< std::pair<int8_t, std::vector<uint16_t>> > ();
905 yylhs.
value.
emplace< std::pair<uint32_t, std::vector<uint16_t>> > ();
938 stack_type::slice range (yystack_, yylen);
954 yylhs.
value.
as < std::vector<uint16_t> > ().push_back(yystack_[1].value.as < uint16_t > ());
962 yylhs.
value.
as < std::vector<uint16_t> > () = std::move(yystack_[5].value.as < std::vector<uint16_t> > ());
963 yylhs.
value.
as < std::vector<uint16_t> > ().push_back(yystack_[1].value.as < uint16_t > ());
973 error(yystack_[3].location,
"relay4 can only be used in DHCPv4.");
975 yylhs.
value.
as < std::vector<uint16_t> > ().push_back(yystack_[1].value.as < uint16_t > ());
983 yylhs.
value.
as < std::vector<uint16_t> > () = std::move(yystack_[5].value.as < std::vector<uint16_t> > ());
984 yylhs.
value.
as < std::vector<uint16_t> > ().push_back(yystack_[1].value.as < uint16_t > ());
994 error(yystack_[8].location,
"relay6 can only be used in DHCPv6.");
996 yylhs.
value.
as < std::pair<int8_t, std::vector<uint16_t>> > ().first = yystack_[6].value.as < int8_t > ();
997 yylhs.
value.
as < std::pair<int8_t, std::vector<uint16_t>> > ().second.push_back(yystack_[1].value.as < uint16_t > ());
999#line 1000 "parser.cc"
1003#line 213 "parser.yy"
1005 yylhs.
value.
as < std::pair<int8_t, std::vector<uint16_t>> > () = std::move(yystack_[5].value.as < std::pair<int8_t, std::vector<uint16_t>> > ());
1006 yylhs.
value.
as < std::pair<int8_t, std::vector<uint16_t>> > ().second.push_back(yystack_[1].value.as < uint16_t > ());
1008#line 1009 "parser.cc"
1012#line 220 "parser.yy"
1014 yylhs.
value.
as < std::pair<uint32_t, std::vector<uint16_t>> > ().first = yystack_[6].value.as < uint32_t > ();
1015 yylhs.
value.
as < std::pair<uint32_t, std::vector<uint16_t>> > ().second.push_back(yystack_[1].value.as < uint16_t > ());
1017#line 1018 "parser.cc"
1021#line 225 "parser.yy"
1023 yylhs.
value.
as < std::pair<uint32_t, std::vector<uint16_t>> > () = std::move(yystack_[5].value.as < std::pair<uint32_t, std::vector<uint16_t>> > ());
1024 yylhs.
value.
as < std::pair<uint32_t, std::vector<uint16_t>> > ().second.push_back(yystack_[1].value.as < uint16_t > ());
1026#line 1027 "parser.cc"
1030#line 233 "parser.yy"
1033 ctx.expression_.push_back(neg);
1035#line 1036 "parser.cc"
1039#line 238 "parser.yy"
1041 unsigned target = ++ctx.label_;
1042 ctx.labels_.push_back(target);
1044 ctx.expression_.push_back(pobf);
1046#line 1047 "parser.cc"
1050#line 243 "parser.yy"
1052 unsigned target = ctx.labels_.back();
1053 ctx.labels_.pop_back();
1055 ctx.expression_.push_back(lab);
1057#line 1058 "parser.cc"
1061#line 250 "parser.yy"
1064 ctx.expression_.push_back(neg);
1066#line 1067 "parser.cc"
1070#line 255 "parser.yy"
1072 unsigned target = ++ctx.label_;
1073 ctx.labels_.push_back(target);
1075 ctx.expression_.push_back(pobt);
1077#line 1078 "parser.cc"
1081#line 260 "parser.yy"
1083 unsigned target = ctx.labels_.back();
1084 ctx.labels_.pop_back();
1086 ctx.expression_.push_back(lab);
1088#line 1089 "parser.cc"
1092#line 267 "parser.yy"
1095 ctx.expression_.push_back(neg);
1097#line 1098 "parser.cc"
1101#line 272 "parser.yy"
1104 ctx.expression_.push_back(eq);
1106#line 1107 "parser.cc"
1110#line 277 "parser.yy"
1113 ctx.expression_.push_back(opt);
1115#line 1116 "parser.cc"
1119#line 282 "parser.yy"
1121 switch (ctx.getUniverse()) {
1125 ctx.expression_.push_back(opt);
1136 error(yystack_[2].location,
"relay4 can only be used in DHCPv4.");
1139#line 1140 "parser.cc"
1143#line 302 "parser.yy"
1145 switch (ctx.getUniverse()) {
1149 ctx.expression_.push_back(opt);
1154 error(yystack_[2].location,
"relay6 can only be used in DHCPv6.");
1157#line 1158 "parser.cc"
1161#line 316 "parser.yy"
1168 ctx.expression_.push_back(exist);
1170#line 1171 "parser.cc"
1174#line 325 "parser.yy"
1181 ctx.expression_.push_back(exist);
1183#line 1184 "parser.cc"
1187#line 334 "parser.yy"
1194 TokenPtr exist(
new TokenVendor(ctx.getUniverse(), yystack_[2].value.as < std::pair<uint32_t, std::vector<uint16_t>> > ().first,
TokenOption::EXISTS, yystack_[2].value.as < std::pair<uint32_t, std::vector<uint16_t>> > ().second));
1195 ctx.expression_.push_back(exist);
1197#line 1198 "parser.cc"
1201#line 344 "parser.yy"
1209 std::string cc = yystack_[1].value.as < std::string > ();
1210 if (!ctx.isClientClassDefined(cc)) {
1211 error(yystack_[1].location,
"Not defined client class '" + cc +
"'");
1214 ctx.expression_.push_back(member);
1216#line 1217 "parser.cc"
1220#line 359 "parser.yy"
1227 ctx.expression_.push_back(match);
1229#line 1230 "parser.cc"
1233#line 370 "parser.yy"
1236 ctx.expression_.push_back(
str);
1238#line 1239 "parser.cc"
1242#line 375 "parser.yy"
1245 ctx.expression_.push_back(hex);
1247#line 1248 "parser.cc"
1251#line 380 "parser.yy"
1254 ctx.expression_.push_back(ip);
1256#line 1257 "parser.cc"
1260#line 385 "parser.yy"
1263 ctx.expression_.push_back(opt);
1265#line 1266 "parser.cc"
1269#line 390 "parser.yy"
1271 switch (ctx.getUniverse()) {
1275 ctx.expression_.push_back(opt);
1286 error(yystack_[2].location,
"relay4 can only be used in DHCPv4.");
1289#line 1290 "parser.cc"
1293#line 411 "parser.yy"
1295 switch (ctx.getUniverse()) {
1299 ctx.expression_.push_back(opt);
1304 error(yystack_[2].location,
"relay6 can only be used in DHCPv6.");
1307#line 1308 "parser.cc"
1311#line 426 "parser.yy"
1314 ctx.expression_.push_back(pkt_metadata);
1316#line 1317 "parser.cc"
1320#line 431 "parser.yy"
1322 switch (ctx.getUniverse()) {
1326 ctx.expression_.push_back(pkt4_field);
1331 error(yystack_[2].location,
"pkt4 can only be used in DHCPv4.");
1334#line 1335 "parser.cc"
1338#line 445 "parser.yy"
1340 switch (ctx.getUniverse()) {
1344 ctx.expression_.push_back(pkt6_field);
1349 error(yystack_[2].location,
"pkt6 can only be used in DHCPv6.");
1352#line 1353 "parser.cc"
1356#line 459 "parser.yy"
1358 switch (ctx.getUniverse()) {
1362 ctx.expression_.push_back(relay6field);
1367 error(yystack_[5].location,
"relay6 can only be used in DHCPv6.");
1370#line 1371 "parser.cc"
1374#line 474 "parser.yy"
1377 ctx.expression_.push_back(sub);
1379#line 1380 "parser.cc"
1383#line 479 "parser.yy"
1386 ctx.expression_.push_back(split);
1388#line 1389 "parser.cc"
1392#line 484 "parser.yy"
1395 ctx.expression_.push_back(conc);
1397#line 1398 "parser.cc"
1401#line 489 "parser.yy"
1404 ctx.expression_.push_back(conc);
1406#line 1407 "parser.cc"
1410#line 494 "parser.yy"
1413 ctx.expression_.push_back(lcase);
1415#line 1416 "parser.cc"
1419#line 499 "parser.yy"
1422 ctx.expression_.push_back(ucase);
1424#line 1425 "parser.cc"
1428#line 504 "parser.yy"
1430 unsigned target = ++ctx.label_;
1431 ctx.labels_.push_back(target);
1433 ctx.expression_.push_back(pabf);
1435#line 1436 "parser.cc"
1439#line 509 "parser.yy"
1441 unsigned target = ctx.labels_.back();
1442 ctx.labels_.pop_back();
1443 unsigned target2 = ++ctx.label_;
1444 ctx.labels_.push_back(target2);
1446 ctx.expression_.push_back(branch);
1448 ctx.expression_.push_back(lab);
1450#line 1451 "parser.cc"
1454#line 518 "parser.yy"
1456 unsigned target = ctx.labels_.back();
1457 ctx.labels_.pop_back();
1459 ctx.expression_.push_back(lab);
1461#line 1462 "parser.cc"
1465#line 525 "parser.yy"
1468 ctx.expression_.push_back(cond);
1470#line 1471 "parser.cc"
1474#line 530 "parser.yy"
1477 ctx.expression_.push_back(tohex);
1479#line 1480 "parser.cc"
1483#line 535 "parser.yy"
1486 ctx.expression_.push_back(addrtotext);
1488#line 1489 "parser.cc"
1492#line 540 "parser.yy"
1495 ctx.expression_.push_back(int8totext);
1497#line 1498 "parser.cc"
1501#line 545 "parser.yy"
1504 ctx.expression_.push_back(int16totext);
1506#line 1507 "parser.cc"
1510#line 550 "parser.yy"
1513 ctx.expression_.push_back(int32totext);
1515#line 1516 "parser.cc"
1519#line 555 "parser.yy"
1522 ctx.expression_.push_back(uint8totext);
1524#line 1525 "parser.cc"
1528#line 560 "parser.yy"
1531 ctx.expression_.push_back(uint16totext);
1533#line 1534 "parser.cc"
1537#line 565 "parser.yy"
1540 ctx.expression_.push_back(uint32totext);
1542#line 1543 "parser.cc"
1546#line 570 "parser.yy"
1553 ctx.expression_.push_back(vendor);
1555#line 1556 "parser.cc"
1559#line 579 "parser.yy"
1567 ctx.expression_.push_back(vendor);
1569#line 1570 "parser.cc"
1573#line 589 "parser.yy"
1579 TokenPtr opt(
new TokenVendor(ctx.getUniverse(), yystack_[2].value.as < std::pair<uint32_t, std::vector<uint16_t>> > ().first, yystack_[0].value.as <
TokenOption::RepresentationType > (), yystack_[2].value.as < std::pair<uint32_t, std::vector<uint16_t>> > ().second));
1580 ctx.expression_.push_back(opt);
1582#line 1583 "parser.cc"
1586#line 598 "parser.yy"
1597 ctx.expression_.push_back(vendor_class);
1599#line 1600 "parser.cc"
1603#line 611 "parser.yy"
1611 uint8_t index = ctx.convertUint8(yystack_[1].value.as < std::string > (), yystack_[1].location);
1614 ctx.expression_.push_back(vendor_class);
1616#line 1617 "parser.cc"
1620#line 624 "parser.yy"
1623 ctx.expression_.push_back(integer);
1625#line 1626 "parser.cc"
1629#line 632 "parser.yy"
1631 yylhs.
value.
as < uint32_t > () = ctx.convertUint32(yystack_[0].value.as < std::string > (), yystack_[0].location);
1633#line 1634 "parser.cc"
1637#line 638 "parser.yy"
1639 yylhs.
value.
as < uint16_t > () = ctx.convertOptionCode(yystack_[0].value.as < std::string > (), yystack_[0].location);
1641#line 1642 "parser.cc"
1645#line 642 "parser.yy"
1647 yylhs.
value.
as < uint16_t > () = ctx.convertOptionName(yystack_[0].value.as < std::string > (), yystack_[0].location);
1649#line 1650 "parser.cc"
1653#line 648 "parser.yy"
1655 yylhs.
value.
as < uint16_t > () = ctx.convertOptionCode(yystack_[0].value.as < std::string > (), yystack_[0].location);
1657#line 1658 "parser.cc"
1661#line 654 "parser.yy"
1665#line 1666 "parser.cc"
1669#line 658 "parser.yy"
1673#line 1674 "parser.cc"
1677#line 664 "parser.yy"
1679 yylhs.
value.
as < int8_t > () = ctx.convertNestLevelNumber(yystack_[0].value.as < std::string > (), yystack_[0].location);
1681#line 1682 "parser.cc"
1685#line 673 "parser.yy"
1689#line 1690 "parser.cc"
1693#line 677 "parser.yy"
1697#line 1698 "parser.cc"
1701#line 681 "parser.yy"
1705#line 1706 "parser.cc"
1709#line 685 "parser.yy"
1713#line 1714 "parser.cc"
1717#line 691 "parser.yy"
1719 yylhs.
value.
as < uint32_t > () = ctx.convertUint32(yystack_[0].value.as < std::string > (), yystack_[0].location);
1721#line 1722 "parser.cc"
1725#line 695 "parser.yy"
1727 yylhs.
value.
as < uint32_t > () = 0;
1729#line 1730 "parser.cc"
1733#line 701 "parser.yy"
1737#line 1738 "parser.cc"
1741#line 705 "parser.yy"
1745#line 1746 "parser.cc"
1749#line 709 "parser.yy"
1753#line 1754 "parser.cc"
1757#line 713 "parser.yy"
1761#line 1762 "parser.cc"
1765#line 717 "parser.yy"
1769#line 1770 "parser.cc"
1773#line 721 "parser.yy"
1777#line 1778 "parser.cc"
1781#line 725 "parser.yy"
1785#line 1786 "parser.cc"
1789#line 729 "parser.yy"
1793#line 1794 "parser.cc"
1797#line 733 "parser.yy"
1801#line 1802 "parser.cc"
1805#line 739 "parser.yy"
1809#line 1810 "parser.cc"
1813#line 743 "parser.yy"
1817#line 1818 "parser.cc"
1821#line 749 "parser.yy"
1825#line 1826 "parser.cc"
1829#line 753 "parser.yy"
1833#line 1834 "parser.cc"
1837#line 759 "parser.yy"
1840 ctx.expression_.push_back(
str);
1842#line 1843 "parser.cc"
1846#line 766 "parser.yy"
1849 ctx.expression_.push_back(
str);
1851#line 1852 "parser.cc"
1855#line 771 "parser.yy"
1858 ctx.expression_.push_back(
str);
1860#line 1861 "parser.cc"
1864#line 778 "parser.yy"
1867 ctx.expression_.push_back(
str);
1869#line 1870 "parser.cc"
1873#line 1874 "parser.cc"
1882 YYCDEBUG <<
"Caught exception: " << yyexc.what() <<
'\n';
1892 yypush_ (YY_NULLPTR,
YY_MOVE (yylhs));
1906 std::string msg = yysyntax_error_ (yyctx);
1912 if (yyerrstatus_ == 3)
1920 else if (!yyla.
empty ())
1922 yy_destroy_ (
"Error: discarding", yyla);
1956 yyn = yypact_[+yystack_[0].state];
1957 if (!yy_pact_value_is_default_ (yyn))
1960 if (0 <= yyn && yyn <= yylast_
1963 yyn = yytable_[yyn];
1970 if (yystack_.size () == 1)
1973 yyerror_range[1].
location = yystack_[0].location;
1974 yy_destroy_ (
"Error: popping", yystack_[0]);
1979 stack_symbol_type error_token;
1985 error_token.state = state_type (yyn);
1986 yypush_ (
"Shifting",
YY_MOVE (error_token));
2012 yy_destroy_ (
"Cleanup: discarding lookahead", yyla);
2018 while (1 < yystack_.size ())
2020 yy_destroy_ (
"Cleanup: popping", yystack_[0]);
2029 YYCDEBUG <<
"Exception caught: cleaning lookahead and stack\n";
2033 yy_destroy_ (YY_NULLPTR, yyla);
2035 while (1 < yystack_.size ())
2037 yy_destroy_ (YY_NULLPTR, yystack_[0]);
2057 EvalParser::yytnamerr_ (
const char *yystr)
2062 char const *yyp = yystr;
2069 goto do_not_strip_quotes;
2073 goto do_not_strip_quotes;
2085 do_not_strip_quotes: ;
2094 return yytnamerr_ (yytname_[yysymbol]);
2101 : yyparser_ (yyparser)
2111 const int yyn = yypact_[+yyparser_.yystack_[0].state];
2112 if (!yy_pact_value_is_default_ (yyn))
2117 const int yyxbegin = yyn < 0 ? -yyn : 0;
2119 const int yychecklim = yylast_ - yyn + 1;
2121 for (
int yyx = yyxbegin; yyx < yyxend; ++yyx)
2123 && !yy_table_value_is_error_ (yytable_[yyx + yyn]))
2127 else if (yycount == yyargn)
2134 if (yyarg && yycount == 0 && 0 < yyargn)
2145 EvalParser::yy_syntax_error_arguments_ (
const context& yyctx,
2176 yyarg[0] = yyctx.
token ();
2177 int yyn = yyctx.
expected_tokens (yyarg ? yyarg + 1 : yyarg, yyargn - 1);
2185 EvalParser::yysyntax_error_ (
const context& yyctx)
const
2188 enum { YYARGS_MAX = 5 };
2191 int yycount = yy_syntax_error_arguments_ (yyctx, yyarg, YYARGS_MAX);
2193 char const* yyformat = YY_NULLPTR;
2196#define YYCASE_(N, S) \
2202 YYCASE_ (1,
YY_(
"syntax error, unexpected %s"));
2203 YYCASE_ (2,
YY_(
"syntax error, unexpected %s, expecting %s"));
2204 YYCASE_ (3,
YY_(
"syntax error, unexpected %s, expecting %s or %s"));
2205 YYCASE_ (4,
YY_(
"syntax error, unexpected %s, expecting %s or %s or %s"));
2206 YYCASE_ (5,
YY_(
"syntax error, unexpected %s, expecting %s or %s or %s or %s"));
2212 std::ptrdiff_t yyi = 0;
2213 for (
char const* yyp = yyformat; *yyp; ++yyp)
2214 if (yyp[0] ==
'%' && yyp[1] ==
's' && yyi < yycount)
2225 const short EvalParser::yypact_ninf_ = -193;
2227 const signed char EvalParser::yytable_ninf_ = -1;
2230 EvalParser::yypact_[] =
2232 64, 207, 89, 58, 207, 207, -9, 17, 46, 20,
2233 56, 90, 113, 116, 145, 150, 173, 177, 184, 185,
2234 203, 208, 214, 220, 226, 231, 272, 243, 105, 166,
2235 282, -193, -193, -193, -193, -193, 244, 251, 252, 283,
2236 233, 52, -193, 89, 176, 186, 286, 292, 294, 295,
2237 274, -193, 280, -1, -193, 228, 250, 253, 255, 266,
2238 248, 89, 89, 89, 207, 207, 89, 89, 89, 89,
2239 89, 89, 89, 89, 89, 89, 23, 45, 257, 45,
2240 261, 258, 146, 187, 205, 211, -193, 207, -193, 207,
2241 89, 89, 2, 45, 45, 86, 152, 217, 225, -193,
2242 -193, -193, -193, 299, -193, 303, -193, 306, 321, -193,
2243 -193, -193, -193, -193, -193, -193, -193, -193, -193, -193,
2244 -193, -193, -193, -193, 43, 256, 259, 143, 153, 260,
2245 3, 6, 7, 8, 9, 10, 11, 12, 14, -193,
2246 -193, -193, -193, -193, 308, -193, 309, -193, 289, 312,
2247 -193, -193, -193, -193, 313, -193, -193, 314, -193, -193,
2248 315, -193, -193, 207, 327, 207, 163, 274, -193, 316,
2249 317, -193, -193, 318, -193, 270, 89, 89, -193, 89,
2250 89, -193, -193, -193, -193, -193, -193, -193, -193, -193,
2251 319, 320, 89, 250, 228, 228, 228, -193, 158, 322,
2252 323, 13, -193, 301, 267, 15, 89, 268, 33, -18,
2253 65, 42, 325, 326, 328, 329, 285, 337, 332, -193,
2254 -193, -193, -33, 284, -193, 271, 89, -193, -193, 334,
2255 335, -193, -193, -193, -193, -193, -193, 250, -193, -193,
2256 349, -193, 350, -193, 53, 290, 250, 339, -193, -193,
2257 89, -193, 340, 341, -193, 73, -193, -193, -193
2261 EvalParser::yydefact_[] =
2263 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
2264 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
2265 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
2266 0, 30, 65, 31, 32, 2, 0, 0, 0, 0,
2267 4, 0, 63, 0, 0, 0, 0, 0, 0, 0,
2268 3, 1, 0, 0, 14, 0, 0, 0, 0, 0,
2269 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
2270 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
2271 0, 0, 0, 0, 0, 0, 15, 0, 18, 0,
2272 0, 0, 0, 0, 0, 0, 0, 0, 0, 13,
2273 64, 66, 67, 0, 68, 0, 71, 0, 0, 72,
2274 73, 74, 75, 36, 78, 79, 80, 81, 82, 83,
2275 84, 85, 86, 37, 0, 0, 0, 0, 0, 0,
2276 0, 0, 0, 0, 0, 0, 0, 0, 0, 87,
2277 88, 38, 77, 76, 0, 59, 0, 58, 0, 0,
2278 69, 70, 22, 33, 0, 23, 34, 0, 24, 35,
2279 0, 27, 60, 0, 17, 0, 20, 21, 43, 0,
2280 0, 5, 7, 0, 28, 0, 0, 0, 46, 0,
2281 0, 51, 52, 53, 54, 55, 56, 57, 44, 45,
2282 0, 0, 0, 0, 0, 0, 0, 16, 19, 0,
2283 0, 0, 91, 0, 0, 0, 0, 0, 0, 0,
2284 0, 0, 0, 0, 0, 0, 0, 0, 0, 89,
2285 90, 39, 0, 0, 42, 0, 0, 50, 25, 61,
2286 0, 26, 29, 6, 8, 10, 12, 0, 93, 92,
2287 0, 94, 0, 47, 0, 0, 0, 0, 40, 41,
2288 0, 49, 0, 0, 9, 0, 62, 11, 48
2292 EvalParser::yypgoto_[] =
2294 -193, -193, -193, 16, 21, 26, 31, 34, -193, -193,
2295 -2, -193, -193, -193, 72, -192, 117, -193, -193, 51,
2296 -193, -193, -193, -193, -193, -193
2300 EvalParser::yydefgoto_[] =
2302 0, 3, 35, 46, 47, 48, 49, 40, 163, 165,
2303 41, 206, 250, 42, 103, 105, 153, 107, 113, 144,
2304 123, 141, 221, 203, 240, 242
2308 EvalParser::yytable_[] =
2310 50, 212, 53, 100, 228, 238, 100, 181, 55, 90,
2311 182, 183, 184, 185, 186, 187, 188, 36, 189, 224,
2312 36, 36, 37, 58, 218, 37, 37, 38, 219, 220,
2313 38, 38, 39, 239, 56, 39, 39, 227, 52, 54,
2314 91, 92, 229, 91, 91, 247, 232, 91, 91, 91,
2315 91, 91, 91, 91, 253, 91, 91, 251, 51, 124,
2316 125, 126, 90, 57, 129, 130, 131, 132, 133, 134,
2317 135, 136, 137, 138, 91, 59, 230, 258, 139, 140,
2318 36, 36, 175, 91, 91, 37, 37, 231, 167, 168,
2319 38, 38, 43, 91, 91, 39, 39, 149, 127, 128,
2320 6, 7, 8, 36, 142, 36, 150, 151, 37, 60,
2321 37, 143, 10, 38, 91, 38, 61, 11, 39, 62,
2322 39, 164, 77, 166, 78, 12, 13, 1, 2, 14,
2323 146, 15, 16, 17, 18, 19, 20, 21, 22, 23,
2324 24, 25, 26, 27, 169, 170, 44, 45, 63, 86,
2325 87, 88, 89, 64, 31, 32, 33, 149, 34, 86,
2326 87, 88, 89, 154, 86, 87, 150, 151, 152, 86,
2327 87, 88, 150, 151, 204, 205, 65, 207, 208, 36,
2328 66, 36, 178, 79, 37, 80, 37, 67, 68, 38,
2329 211, 38, 179, 93, 39, 78, 39, 197, 154, 198,
2330 156, 159, 162, 94, 225, 80, 69, 150, 151, 155,
2331 4, 70, 5, 156, 159, 162, 157, 71, 6, 7,
2332 8, 9, 160, 72, 244, 150, 151, 158, 157, 73,
2333 10, 150, 151, 161, 74, 11, 160, 150, 151, 86,
2334 87, 88, 89, 12, 13, 150, 151, 14, 255, 15,
2335 16, 17, 18, 19, 20, 21, 22, 23, 24, 25,
2336 26, 27, 76, 82, 28, 29, 213, 214, 215, 30,
2337 83, 84, 31, 32, 33, 75, 34, 114, 115, 116,
2338 117, 118, 119, 120, 99, 81, 86, 87, 88, 89,
2339 109, 110, 111, 112, 101, 176, 102, 91, 177, 180,
2340 91, 91, 85, 121, 122, 95, 223, 226, 91, 91,
2341 243, 96, 91, 97, 98, 91, 104, 171, 145, 106,
2342 108, 172, 147, 148, 173, 174, 190, 191, 192, 193,
2343 194, 195, 196, 86, 199, 200, 202, 201, 209, 210,
2344 222, 216, 217, 233, 234, 229, 235, 236, 230, 237,
2345 241, 245, 246, 248, 249, 0, 252, 254, 256, 257
2349 EvalParser::yycheck_[] =
2351 2, 193, 4, 4, 22, 38, 4, 4, 17, 10,
2352 4, 4, 4, 4, 4, 4, 4, 1, 4, 4,
2353 4, 5, 1, 3, 11, 4, 5, 1, 15, 16,
2354 4, 5, 1, 66, 17, 4, 5, 4, 4, 5,
2355 41, 43, 60, 41, 41, 237, 4, 41, 41, 41,
2356 41, 41, 41, 41, 246, 41, 41, 4, 0, 61,
2357 62, 63, 10, 17, 66, 67, 68, 69, 70, 71,
2358 72, 73, 74, 75, 41, 19, 11, 4, 55, 56,
2359 64, 65, 39, 41, 41, 64, 65, 22, 90, 91,
2360 64, 65, 3, 41, 41, 64, 65, 11, 64, 65,
2361 11, 12, 13, 87, 59, 89, 20, 21, 87, 19,
2362 89, 66, 23, 87, 41, 89, 3, 28, 87, 3,
2363 89, 87, 17, 89, 19, 36, 37, 63, 64, 40,
2364 79, 42, 43, 44, 45, 46, 47, 48, 49, 50,
2365 51, 52, 53, 54, 93, 94, 57, 58, 3, 6,
2366 7, 8, 9, 3, 65, 66, 67, 11, 69, 6,
2367 7, 8, 9, 11, 6, 7, 20, 21, 22, 6,
2368 7, 8, 20, 21, 176, 177, 3, 179, 180, 163,
2369 3, 165, 39, 17, 163, 19, 165, 3, 3, 163,
2370 192, 165, 39, 17, 163, 19, 165, 163, 11, 165,
2371 83, 84, 85, 17, 206, 19, 3, 20, 21, 22,
2372 3, 3, 5, 96, 97, 98, 11, 3, 11, 12,
2373 13, 14, 11, 3, 226, 20, 21, 22, 11, 3,
2374 23, 20, 21, 22, 3, 28, 11, 20, 21, 6,
2375 7, 8, 9, 36, 37, 20, 21, 40, 250, 42,
2376 43, 44, 45, 46, 47, 48, 49, 50, 51, 52,
2377 53, 54, 19, 19, 57, 58, 194, 195, 196, 62,
2378 19, 19, 65, 66, 67, 3, 69, 29, 30, 31,
2379 32, 33, 34, 35, 4, 3, 6, 7, 8, 9,
2380 24, 25, 26, 27, 66, 39, 68, 41, 39, 39,
2381 41, 41, 19, 55, 56, 19, 39, 39, 41, 41,
2382 39, 19, 41, 19, 19, 41, 66, 18, 61, 66,
2383 65, 18, 61, 65, 18, 4, 18, 18, 39, 17,
2384 17, 17, 17, 6, 18, 18, 66, 19, 19, 19,
2385 39, 19, 19, 18, 18, 60, 18, 18, 11, 17,
2386 66, 17, 17, 4, 4, -1, 66, 18, 18, 18
2390 EvalParser::yystos_[] =
2392 0, 63, 64, 71, 3, 5, 11, 12, 13, 14,
2393 23, 28, 36, 37, 40, 42, 43, 44, 45, 46,
2394 47, 48, 49, 50, 51, 52, 53, 54, 57, 58,
2395 62, 65, 66, 67, 69, 72, 73, 74, 75, 76,
2396 77, 80, 83, 3, 57, 58, 73, 74, 75, 76,
2397 80, 0, 77, 80, 77, 17, 17, 17, 3, 19,
2398 19, 3, 3, 3, 3, 3, 3, 3, 3, 3,
2399 3, 3, 3, 3, 3, 3, 19, 17, 19, 17,
2400 19, 3, 19, 19, 19, 19, 6, 7, 8, 9,
2401 10, 41, 80, 17, 17, 19, 19, 19, 19, 4,
2402 4, 66, 68, 84, 66, 85, 66, 87, 65, 24,
2403 25, 26, 27, 88, 29, 30, 31, 32, 33, 34,
2404 35, 55, 56, 90, 80, 80, 80, 77, 77, 80,
2405 80, 80, 80, 80, 80, 80, 80, 80, 80, 55,
2406 56, 91, 59, 66, 89, 61, 89, 61, 65, 11,
2407 20, 21, 22, 86, 11, 22, 86, 11, 22, 86,
2408 11, 22, 86, 78, 77, 79, 77, 80, 80, 89,
2409 89, 18, 18, 18, 4, 39, 39, 39, 39, 39,
2410 39, 4, 4, 4, 4, 4, 4, 4, 4, 4,
2411 18, 18, 39, 17, 17, 17, 17, 77, 77, 18,
2412 18, 19, 66, 93, 80, 80, 81, 80, 80, 19,
2413 19, 80, 85, 84, 84, 84, 19, 19, 11, 15,
2414 16, 92, 39, 39, 4, 80, 39, 4, 22, 60,
2415 11, 22, 4, 18, 18, 18, 18, 17, 38, 66,
2416 94, 66, 95, 39, 80, 17, 17, 85, 4, 4,
2417 82, 4, 66, 85, 18, 80, 18, 18, 4
2421 EvalParser::yyr1_[] =
2423 0, 70, 71, 71, 72, 73, 73, 74, 74, 75,
2424 75, 76, 76, 77, 77, 78, 77, 77, 79, 77,
2425 77, 77, 77, 77, 77, 77, 77, 77, 77, 77,
2426 80, 80, 80, 80, 80, 80, 80, 80, 80, 80,
2427 80, 80, 80, 80, 80, 80, 81, 82, 80, 80,
2428 80, 80, 80, 80, 80, 80, 80, 80, 80, 80,
2429 80, 80, 80, 80, 80, 83, 84, 84, 85, 86,
2430 86, 87, 88, 88, 88, 88, 89, 89, 90, 90,
2431 90, 90, 90, 90, 90, 90, 90, 91, 91, 92,
2436 EvalParser::yyr2_[] =
2438 0, 2, 2, 2, 1, 4, 6, 4, 6, 9,
2439 6, 9, 6, 3, 2, 0, 4, 3, 0, 4,
2440 3, 3, 3, 3, 3, 6, 6, 3, 4, 6,
2441 1, 1, 1, 3, 3, 3, 3, 3, 3, 6,
2442 8, 8, 6, 3, 4, 4, 0, 0, 10, 8,
2443 6, 4, 4, 4, 4, 4, 4, 4, 3, 3,
2444 3, 6, 9, 1, 3, 1, 1, 1, 1, 1,
2445 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
2446 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
2455 const EvalParser::yytname_[] =
2457 "\"end of file\"",
"error",
"\"invalid token\"",
"\"(\"",
"\")\"",
2458 "\"not\"",
"\"and\"",
"\"sand\"",
"\"or\"",
"\"sor\"",
"\"==\"",
2459 "\"option\"",
"\"relay4\"",
"\"relay6\"",
"\"member\"",
"\"peeraddr\"",
2460 "\"linkaddr\"",
"\"[\"",
"\"]\"",
"\".\"",
"\"text\"",
"\"hex\"",
2461 "\"exists\"",
"\"pkt\"",
"\"iface\"",
"\"src\"",
"\"dst\"",
"\"len\"",
2462 "\"pkt4\"",
"\"mac\"",
"\"hlen\"",
"\"htype\"",
"\"ciaddr\"",
2463 "\"giaddr\"",
"\"yiaddr\"",
"\"siaddr\"",
"\"substring\"",
"\"split\"",
2464 "\"all\"",
"\",\"",
"\"concat\"",
"\"+\"",
"\"ifelse\"",
"\"sifelse\"",
2465 "\"hexstring\"",
"\"addrtotext\"",
"\"int8totext\"",
"\"int16totext\"",
2466 "\"int32totext\"",
"\"uint8totext\"",
"\"uint16totext\"",
2467 "\"uint32totext\"",
"\"lcase\"",
"\"ucase\"",
"\"pkt6\"",
"\"msgtype\"",
2468 "\"transid\"",
"\"vendor-class\"",
"\"vendor\"",
"\"*\"",
"\"data\"",
2469 "\"enterprise\"",
"\"match\"",
"\"top-level bool\"",
2470 "\"top-level string\"",
"\"constant string\"",
"\"integer\"",
2471 "\"constant hexstring\"",
"\"option name\"",
"\"ip address\"",
"$accept",
2472 "start",
"expression",
"option_chain",
"relay4_option_chain",
2473 "relay6_option_chain",
"vendor_option_chain",
"bool_expr",
"$@1",
"$@2",
2474 "string_expr",
"$@3",
"$@4",
"integer_expr",
"option_code",
2475 "sub_option_code",
"option_repr_type",
"nest_level",
"pkt_metadata",
2476 "enterprise_id",
"pkt4_field",
"pkt6_field",
"relay6_field",
2477 "start_expr",
"length_expr",
"int_expr", YY_NULLPTR
2484 EvalParser::yyrline_[] =
2486 0, 168, 168, 169, 174, 177, 181, 188, 196, 203,
2487 212, 219, 224, 231, 232, 238, 237, 249, 255, 254,
2488 266, 271, 276, 281, 301, 315, 324, 333, 343, 358,
2489 369, 374, 379, 384, 389, 410, 425, 430, 444, 458,
2490 473, 478, 483, 488, 493, 498, 504, 509, 503, 524,
2491 529, 534, 539, 544, 549, 554, 559, 564, 569, 578,
2492 588, 597, 610, 623, 628, 631, 637, 641, 647, 653,
2493 657, 663, 672, 676, 680, 684, 690, 694, 700, 704,
2494 708, 712, 716, 720, 724, 728, 732, 738, 742, 748,
2495 752, 758, 765, 770, 777
2499 EvalParser::yy_stack_print_ ()
const
2501 *yycdebug_ <<
"Stack now";
2502 for (stack_type::const_iterator
2503 i = yystack_.begin (),
2504 i_end = yystack_.end ();
2506 *yycdebug_ <<
' ' << int (i->state);
2511 EvalParser::yy_reduce_print_ (
int yyrule)
const
2513 int yylno = yyrline_[yyrule];
2514 int yynrhs = yyr2_[yyrule];
2516 *yycdebug_ <<
"Reducing stack by rule " << yyrule - 1
2517 <<
" (line " << yylno <<
"):\n";
2519 for (
int yyi = 0; yyi < yynrhs; yyi++)
2521 yystack_[(yynrhs) - (yyi + 1)]);
2528#line 2529 "parser.cc"
2530#line 784 "parser.yy"
2534 const std::string& what)
2536 ctx.error(loc, what);
Token that represents logical and operator.
Token that represents unconditional branch.
Token that represents concat operator (concatenates two other tokens).
Token that represents equality operator (compares two other tokens).
Token representing a constant string in hexadecimal format.
Token that represents an alternative.
Token representing a 16 bit integer as a string.
Token representing a 32 bit integer as a string.
Token representing an 8 bit integer as a string.
Token representing an unsigned 32 bit integer.
Token representing an IP address as a string.
Token representing an IP address as a constant string.
Token representing a constant lower case string.
Token that represents regular expression (regex) matching.
Token that represents client class membership.
Token that represents logical negation operator.
Token that represents a value of an option.
RepresentationType
Token representation type.
Token that represents logical or operator.
Token that represents fields of a DHCPv4 packet.
FieldType
enum value that determines the field.
@ CIADDR
ciaddr (IPv4 address)
@ HLEN
hlen (hardware address length)
@ HTYPE
htype (hardware address type)
@ GIADDR
giaddr (IPv4 address)
@ CHADDR
chaddr field (up to 16 bytes link-layer address)
@ YIADDR
yiaddr (IPv4 address)
@ SIADDR
siaddr (IPv4 address)
@ TRANSID
transaction-id (xid)
@ MSGTYPE
message type (not really a field, content of option 53)
Token that represents fields of DHCPv6 packet.
FieldType
enum value that determines the field.
@ TRANSID
transaction id (integer but manipulated as a string)
Token that represents meta data of a DHCP packet.
MetadataType
enum value that determines the field.
@ DST
destination (IP address)
@ IFACE
interface name (string)
Token that represents pop and branch if false.
Token that represents pop or branch if false.
Token that represents pop or branch if true.
Represents a sub-option inserted by the DHCPv4 relay.
Token that represents a value of a field within a DHCPv6 relay encapsulation.
FieldType
enum value that determines the field.
@ LINKADDR
Link address field (IPv6 address).
@ PEERADDR
Peer address field (IPv6 address).
Token that represents a value of an option within a DHCPv6 relay encapsulation.
The order where Token subtypes are declared should be:
Token that represents the substring operator (returns a portion of the supplied string).
Token that converts to hexadecimal string.
Token representing a 16 bit unsigned integer as a string.
Token representing a 32 bit unsigned integer as a string.
Token representing an 8 bit unsigned integer as a string.
Token representing a constant upper case string.
Token that represents vendor class options in DHCPv4 and DHCPv6.
Token that represents vendor options in DHCPv4 and DHCPv6.
@ DATA
data chunk, used in derived vendor-class only
@ ENTERPRISE_ID
enterprise-id field (vendor-info, vendor-class)
Evaluation context, an interface to the expression evaluation.
const symbol_type & lookahead() const YY_NOEXCEPT
int expected_tokens(symbol_kind_type yyarg[], int yyargn) const
Put in YYARG at most YYARGN of the expected tokens, and return the number of tokens stored in YYARG.
context(const EvalParser &yyparser, const symbol_type &yyla)
symbol_kind_type token() const YY_NOEXCEPT
T & as() YY_NOEXCEPT
Accessor to a built T.
T & emplace()
Instantiate an empty T in here.
symbol_kind::symbol_kind_type symbol_kind_type
(Internal) symbol kind.
virtual int parse()
Parse.
location location_type
Symbol locations.
EvalParser(EvalContext &ctx_yyarg)
Build a parser object.
static const symbol_kind_type YYNTOKENS
The number of tokens.
virtual void error(const location_type &loc, const std::string &msg)
Report a syntax error.
static std::string symbol_name(symbol_kind_type yysymbol)
The user-facing name of the symbol whose (internal) number is YYSYMBOL.
#define YYLLOC_DEFAULT(Current, Rhs, N)
#define YY_REDUCE_PRINT(Rule)
#define YY_SYMBOL_PRINT(Title, Symbol)
#define YY_CAST(Type, Val)
#define YY_MOVE_REF(Type)
#define YY_ATTRIBUTE_UNUSED
boost::shared_ptr< Token > TokenPtr
Pointer to a single Token.
Defines the logger used by the top-level component of kea-lfc.
Define the isc::eval::parser class.
void move(basic_symbol &s)
Destructive move, s is emptied into this.
location_type location
The location.
value_type value
The semantic value.
bool empty() const YY_NOEXCEPT
Whether empty.
void clear() YY_NOEXCEPT
Destroy contents, and record that is empty.
symbol_kind_type kind_
The symbol kind.
symbol_kind_type kind() const YY_NOEXCEPT
The (internal) type number (corresponding to type).
"External" symbols: returned by the scanner.
Syntax errors thrown from user actions.
~syntax_error() YY_NOEXCEPT YY_NOTHROW