-// A Bison parser, made by GNU Bison 3.0.5.
+// A Bison parser, made by GNU Bison 3.2.1.
// Skeleton implementation for Bison LALR(1) parsers in C++
// This special exception was added by the Free Software Foundation in
// version 2.2 of Bison.
+// Undocumented macros, especially those whose name start with YY_,
+// are private implementation details. Do not rely on them.
+
+
// Take the name prefix into account.
#define yylex agent_lex
-// First part of user declarations.
-#line 39 "agent_parser.cc" // lalr1.cc:406
-
-# ifndef YY_NULLPTR
-# if defined __cplusplus && 201103L <= __cplusplus
-# define YY_NULLPTR nullptr
-# else
-# define YY_NULLPTR 0
-# endif
-# endif
#include "agent_parser.h"
-// User implementation prologue.
-#line 53 "agent_parser.cc" // lalr1.cc:414
// Unqualified %code blocks.
-#line 33 "agent_parser.yy" // lalr1.cc:415
+#line 33 "agent_parser.yy" // lalr1.cc:438
#include <agent/parser_context.h>
-#line 59 "agent_parser.cc" // lalr1.cc:415
+#line 51 "agent_parser.cc" // lalr1.cc:438
#ifndef YY_
# endif
#endif
+// Whether we are compiled with exception support.
+#ifndef YY_EXCEPTIONS
+# if defined __GNUC__ && !defined __EXCEPTIONS
+# define YY_EXCEPTIONS 0
+# else
+# define YY_EXCEPTIONS 1
+# endif
+#endif
+
#define YYRHSLOC(Rhs, K) ((Rhs)[K].location)
/* YYLLOC_DEFAULT -- Set CURRENT to span from RHS[1] to RHS[N].
If N is 0, then set CURRENT to the empty location which ends
#define YYERROR goto yyerrorlab
#define YYRECOVERING() (!!yyerrstatus_)
-#line 14 "agent_parser.yy" // lalr1.cc:481
+#line 14 "agent_parser.yy" // lalr1.cc:513
namespace isc { namespace agent {
-#line 145 "agent_parser.cc" // lalr1.cc:481
+#line 146 "agent_parser.cc" // lalr1.cc:513
/* Return YYSTR after stripping away unnecessary quotes and
backslashes, so that it's suitable for yyerror. The heuristic is
AgentParser::stack_symbol_type::stack_symbol_type ()
{}
- AgentParser::stack_symbol_type::stack_symbol_type (const stack_symbol_type& that)
- : super_type (that.state, that.location)
+ AgentParser::stack_symbol_type::stack_symbol_type (YY_RVREF (stack_symbol_type) that)
+ : super_type (YY_MOVE (that.state), YY_MOVE (that.location))
{
switch (that.type_get ())
{
case 53: // value
case 56: // map_value
case 107: // socket_type_value
- value.copy< ElementPtr > (that.value);
+ value.YY_MOVE_OR_COPY< ElementPtr > (YY_MOVE (that.value));
break;
case 44: // "boolean"
- value.copy< bool > (that.value);
+ value.YY_MOVE_OR_COPY< bool > (YY_MOVE (that.value));
break;
case 43: // "floating point"
- value.copy< double > (that.value);
+ value.YY_MOVE_OR_COPY< double > (YY_MOVE (that.value));
break;
case 42: // "integer"
- value.copy< int64_t > (that.value);
+ value.YY_MOVE_OR_COPY< int64_t > (YY_MOVE (that.value));
break;
case 41: // "constant string"
- value.copy< std::string > (that.value);
+ value.YY_MOVE_OR_COPY< std::string > (YY_MOVE (that.value));
break;
default:
break;
}
+#if defined __cplusplus && 201103L <= __cplusplus
+ // that is emptied.
+ that.state = empty_state;
+#endif
}
- AgentParser::stack_symbol_type::stack_symbol_type (state_type s, symbol_type& that)
- : super_type (s, that.location)
+ AgentParser::stack_symbol_type::stack_symbol_type (state_type s, YY_MOVE_REF (symbol_type) that)
+ : super_type (s, YY_MOVE (that.location))
{
switch (that.type_get ())
{
case 53: // value
case 56: // map_value
case 107: // socket_type_value
- value.move< ElementPtr > (that.value);
+ value.move< ElementPtr > (YY_MOVE (that.value));
break;
case 44: // "boolean"
- value.move< bool > (that.value);
+ value.move< bool > (YY_MOVE (that.value));
break;
case 43: // "floating point"
- value.move< double > (that.value);
+ value.move< double > (YY_MOVE (that.value));
break;
case 42: // "integer"
- value.move< int64_t > (that.value);
+ value.move< int64_t > (YY_MOVE (that.value));
break;
case 41: // "constant string"
- value.move< std::string > (that.value);
+ value.move< std::string > (YY_MOVE (that.value));
break;
default:
that.type = empty_symbol;
}
+#if !defined __cplusplus || __cplusplus < 201103L
AgentParser::stack_symbol_type&
- AgentParser::stack_symbol_type::operator= (const stack_symbol_type& that)
+ AgentParser::stack_symbol_type::operator= (stack_symbol_type& that)
{
state = that.state;
switch (that.type_get ())
case 53: // value
case 56: // map_value
case 107: // socket_type_value
- value.copy< ElementPtr > (that.value);
+ value.move< ElementPtr > (that.value);
break;
case 44: // "boolean"
- value.copy< bool > (that.value);
+ value.move< bool > (that.value);
break;
case 43: // "floating point"
- value.copy< double > (that.value);
+ value.move< double > (that.value);
break;
case 42: // "integer"
- value.copy< int64_t > (that.value);
+ value.move< int64_t > (that.value);
break;
case 41: // "constant string"
- value.copy< std::string > (that.value);
+ value.move< std::string > (that.value);
break;
default:
}
location = that.location;
+ // that is emptied.
+ that.state = empty_state;
return *this;
}
-
+#endif
template <typename Base>
void
{
case 41: // "constant string"
-#line 103 "agent_parser.yy" // lalr1.cc:635
+#line 103 "agent_parser.yy" // lalr1.cc:672
{ yyoutput << yysym.value.template as< std::string > (); }
-#line 378 "agent_parser.cc" // lalr1.cc:635
+#line 386 "agent_parser.cc" // lalr1.cc:672
break;
case 42: // "integer"
-#line 103 "agent_parser.yy" // lalr1.cc:635
+#line 103 "agent_parser.yy" // lalr1.cc:672
{ yyoutput << yysym.value.template as< int64_t > (); }
-#line 385 "agent_parser.cc" // lalr1.cc:635
+#line 393 "agent_parser.cc" // lalr1.cc:672
break;
case 43: // "floating point"
-#line 103 "agent_parser.yy" // lalr1.cc:635
+#line 103 "agent_parser.yy" // lalr1.cc:672
{ yyoutput << yysym.value.template as< double > (); }
-#line 392 "agent_parser.cc" // lalr1.cc:635
+#line 400 "agent_parser.cc" // lalr1.cc:672
break;
case 44: // "boolean"
-#line 103 "agent_parser.yy" // lalr1.cc:635
+#line 103 "agent_parser.yy" // lalr1.cc:672
{ yyoutput << yysym.value.template as< bool > (); }
-#line 399 "agent_parser.cc" // lalr1.cc:635
+#line 407 "agent_parser.cc" // lalr1.cc:672
break;
case 53: // value
-#line 103 "agent_parser.yy" // lalr1.cc:635
+#line 103 "agent_parser.yy" // lalr1.cc:672
{ yyoutput << yysym.value.template as< ElementPtr > (); }
-#line 406 "agent_parser.cc" // lalr1.cc:635
+#line 414 "agent_parser.cc" // lalr1.cc:672
break;
case 56: // map_value
-#line 103 "agent_parser.yy" // lalr1.cc:635
+#line 103 "agent_parser.yy" // lalr1.cc:672
{ yyoutput << yysym.value.template as< ElementPtr > (); }
-#line 413 "agent_parser.cc" // lalr1.cc:635
+#line 421 "agent_parser.cc" // lalr1.cc:672
break;
case 107: // socket_type_value
-#line 103 "agent_parser.yy" // lalr1.cc:635
+#line 103 "agent_parser.yy" // lalr1.cc:672
{ yyoutput << yysym.value.template as< ElementPtr > (); }
-#line 420 "agent_parser.cc" // lalr1.cc:635
+#line 428 "agent_parser.cc" // lalr1.cc:672
break;
#endif
void
- AgentParser::yypush_ (const char* m, state_type s, symbol_type& sym)
+ AgentParser::yypush_ (const char* m, YY_MOVE_REF (stack_symbol_type) sym)
{
- stack_symbol_type t (s, sym);
- yypush_ (m, t);
+ if (m)
+ YY_SYMBOL_PRINT (m, sym);
+ yystack_.push (YY_MOVE (sym));
}
void
- AgentParser::yypush_ (const char* m, stack_symbol_type& s)
+ AgentParser::yypush_ (const char* m, state_type s, YY_MOVE_REF (symbol_type) sym)
{
- if (m)
- YY_SYMBOL_PRINT (m, s);
- yystack_.push (s);
+#if defined __cplusplus && 201103L <= __cplusplus
+ yypush_ (m, stack_symbol_type (s, std::move (sym)));
+#else
+ stack_symbol_type ss (s, sym);
+ yypush_ (m, ss);
+#endif
}
void
- AgentParser::yypop_ (unsigned n)
+ AgentParser::yypop_ (int n)
{
yystack_.pop (n);
}
return yyvalue == yytable_ninf_;
}
+ int
+ AgentParser::operator() ()
+ {
+ return parse ();
+ }
+
int
AgentParser::parse ()
{
/// The return value of parse ().
int yyresult;
- // FIXME: This shoud be completely indented. It is not yet to
- // avoid gratuitous conflicts when merging into the master branch.
+#if YY_EXCEPTIONS
try
+#endif // YY_EXCEPTIONS
{
YYCDEBUG << "Starting parse\n";
location values to have been already stored, initialize these
stacks with a primary value. */
yystack_.clear ();
- yypush_ (YY_NULLPTR, 0, yyla);
+ yypush_ (YY_NULLPTR, 0, YY_MOVE (yyla));
// A new symbol was pushed on the stack.
yynewstate:
// Backup.
yybackup:
-
// Try to take a decision without lookahead.
yyn = yypact_[yystack_[0].state];
if (yy_pact_value_is_default_ (yyn))
if (yyla.empty ())
{
YYCDEBUG << "Reading a token: ";
+#if YY_EXCEPTIONS
try
+#endif // YY_EXCEPTIONS
{
symbol_type yylookahead (yylex (ctx));
yyla.move (yylookahead);
}
+#if YY_EXCEPTIONS
catch (const syntax_error& yyexc)
{
error (yyexc);
goto yyerrlab1;
}
+#endif // YY_EXCEPTIONS
}
YY_SYMBOL_PRINT ("Next token is", yyla);
--yyerrstatus_;
// Shift the lookahead token.
- yypush_ ("Shifting", yyn, yyla);
+ yypush_ ("Shifting", yyn, YY_MOVE (yyla));
goto yynewstate;
/*-----------------------------------------------------------.
case 53: // value
case 56: // map_value
case 107: // socket_type_value
- yylhs.value.build< ElementPtr > ();
+ yylhs.value.emplace< ElementPtr > ();
break;
case 44: // "boolean"
- yylhs.value.build< bool > ();
+ yylhs.value.emplace< bool > ();
break;
case 43: // "floating point"
- yylhs.value.build< double > ();
+ yylhs.value.emplace< double > ();
break;
case 42: // "integer"
- yylhs.value.build< int64_t > ();
+ yylhs.value.emplace< int64_t > ();
break;
case 41: // "constant string"
- yylhs.value.build< std::string > ();
+ yylhs.value.emplace< std::string > ();
break;
default:
// Perform the reduction.
YY_REDUCE_PRINT (yyn);
+#if YY_EXCEPTIONS
try
+#endif // YY_EXCEPTIONS
{
switch (yyn)
{
case 2:
-#line 114 "agent_parser.yy" // lalr1.cc:856
+#line 114 "agent_parser.yy" // lalr1.cc:907
{ ctx.ctx_ = ctx.NO_KEYWORDS; }
-#line 660 "agent_parser.cc" // lalr1.cc:856
+#line 683 "agent_parser.cc" // lalr1.cc:907
break;
case 4:
-#line 115 "agent_parser.yy" // lalr1.cc:856
+#line 115 "agent_parser.yy" // lalr1.cc:907
{ ctx.ctx_ = ctx.CONFIG; }
-#line 666 "agent_parser.cc" // lalr1.cc:856
+#line 689 "agent_parser.cc" // lalr1.cc:907
break;
case 6:
-#line 116 "agent_parser.yy" // lalr1.cc:856
+#line 116 "agent_parser.yy" // lalr1.cc:907
{ ctx.ctx_ = ctx.AGENT; }
-#line 672 "agent_parser.cc" // lalr1.cc:856
+#line 695 "agent_parser.cc" // lalr1.cc:907
break;
case 8:
-#line 124 "agent_parser.yy" // lalr1.cc:856
+#line 124 "agent_parser.yy" // lalr1.cc:907
{
// Parse the Control-agent map
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.push_back(m);
}
-#line 682 "agent_parser.cc" // lalr1.cc:856
+#line 705 "agent_parser.cc" // lalr1.cc:907
break;
case 9:
-#line 128 "agent_parser.yy" // lalr1.cc:856
+#line 128 "agent_parser.yy" // lalr1.cc:907
{
// parsing completed
}
-#line 690 "agent_parser.cc" // lalr1.cc:856
+#line 713 "agent_parser.cc" // lalr1.cc:907
break;
case 10:
-#line 135 "agent_parser.yy" // lalr1.cc:856
+#line 135 "agent_parser.yy" // lalr1.cc:907
{
// Push back the JSON value on the stack
ctx.stack_.push_back(yystack_[0].value.as< ElementPtr > ());
}
-#line 699 "agent_parser.cc" // lalr1.cc:856
+#line 722 "agent_parser.cc" // lalr1.cc:907
break;
case 11:
-#line 141 "agent_parser.yy" // lalr1.cc:856
+#line 141 "agent_parser.yy" // lalr1.cc:907
{ yylhs.value.as< ElementPtr > () = ElementPtr(new IntElement(yystack_[0].value.as< int64_t > (), ctx.loc2pos(yystack_[0].location))); }
-#line 705 "agent_parser.cc" // lalr1.cc:856
+#line 728 "agent_parser.cc" // lalr1.cc:907
break;
case 12:
-#line 142 "agent_parser.yy" // lalr1.cc:856
+#line 142 "agent_parser.yy" // lalr1.cc:907
{ yylhs.value.as< ElementPtr > () = ElementPtr(new DoubleElement(yystack_[0].value.as< double > (), ctx.loc2pos(yystack_[0].location))); }
-#line 711 "agent_parser.cc" // lalr1.cc:856
+#line 734 "agent_parser.cc" // lalr1.cc:907
break;
case 13:
-#line 143 "agent_parser.yy" // lalr1.cc:856
+#line 143 "agent_parser.yy" // lalr1.cc:907
{ yylhs.value.as< ElementPtr > () = ElementPtr(new BoolElement(yystack_[0].value.as< bool > (), ctx.loc2pos(yystack_[0].location))); }
-#line 717 "agent_parser.cc" // lalr1.cc:856
+#line 740 "agent_parser.cc" // lalr1.cc:907
break;
case 14:
-#line 144 "agent_parser.yy" // lalr1.cc:856
+#line 144 "agent_parser.yy" // lalr1.cc:907
{ yylhs.value.as< ElementPtr > () = ElementPtr(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location))); }
-#line 723 "agent_parser.cc" // lalr1.cc:856
+#line 746 "agent_parser.cc" // lalr1.cc:907
break;
case 15:
-#line 145 "agent_parser.yy" // lalr1.cc:856
+#line 145 "agent_parser.yy" // lalr1.cc:907
{ yylhs.value.as< ElementPtr > () = ElementPtr(new NullElement(ctx.loc2pos(yystack_[0].location))); }
-#line 729 "agent_parser.cc" // lalr1.cc:856
+#line 752 "agent_parser.cc" // lalr1.cc:907
break;
case 16:
-#line 146 "agent_parser.yy" // lalr1.cc:856
+#line 146 "agent_parser.yy" // lalr1.cc:907
{ yylhs.value.as< ElementPtr > () = ctx.stack_.back(); ctx.stack_.pop_back(); }
-#line 735 "agent_parser.cc" // lalr1.cc:856
+#line 758 "agent_parser.cc" // lalr1.cc:907
break;
case 17:
-#line 147 "agent_parser.yy" // lalr1.cc:856
+#line 147 "agent_parser.yy" // lalr1.cc:907
{ yylhs.value.as< ElementPtr > () = ctx.stack_.back(); ctx.stack_.pop_back(); }
-#line 741 "agent_parser.cc" // lalr1.cc:856
+#line 764 "agent_parser.cc" // lalr1.cc:907
break;
case 18:
-#line 151 "agent_parser.yy" // lalr1.cc:856
+#line 151 "agent_parser.yy" // lalr1.cc:907
{
// This code is executed when we're about to start parsing
// the content of the map
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.push_back(m);
}
-#line 752 "agent_parser.cc" // lalr1.cc:856
+#line 775 "agent_parser.cc" // lalr1.cc:907
break;
case 19:
-#line 156 "agent_parser.yy" // lalr1.cc:856
+#line 156 "agent_parser.yy" // lalr1.cc:907
{
// map parsing completed. If we ever want to do any wrap up
// (maybe some sanity checking), this would be the best place
// for it.
}
-#line 762 "agent_parser.cc" // lalr1.cc:856
+#line 785 "agent_parser.cc" // lalr1.cc:907
break;
case 20:
-#line 162 "agent_parser.yy" // lalr1.cc:856
+#line 162 "agent_parser.yy" // lalr1.cc:907
{ yylhs.value.as< ElementPtr > () = ctx.stack_.back(); ctx.stack_.pop_back(); }
-#line 768 "agent_parser.cc" // lalr1.cc:856
+#line 791 "agent_parser.cc" // lalr1.cc:907
break;
case 23:
-#line 176 "agent_parser.yy" // lalr1.cc:856
+#line 176 "agent_parser.yy" // lalr1.cc:907
{
// map containing a single entry
ctx.stack_.back()->set(yystack_[2].value.as< std::string > (), yystack_[0].value.as< ElementPtr > ());
}
-#line 777 "agent_parser.cc" // lalr1.cc:856
+#line 800 "agent_parser.cc" // lalr1.cc:907
break;
case 24:
-#line 180 "agent_parser.yy" // lalr1.cc:856
+#line 180 "agent_parser.yy" // lalr1.cc:907
{
// map consisting of a shorter map followed by
// comma and string:value
ctx.stack_.back()->set(yystack_[2].value.as< std::string > (), yystack_[0].value.as< ElementPtr > ());
}
-#line 787 "agent_parser.cc" // lalr1.cc:856
+#line 810 "agent_parser.cc" // lalr1.cc:907
break;
case 25:
-#line 187 "agent_parser.yy" // lalr1.cc:856
+#line 187 "agent_parser.yy" // lalr1.cc:907
{
ElementPtr l(new ListElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.push_back(l);
}
-#line 796 "agent_parser.cc" // lalr1.cc:856
+#line 819 "agent_parser.cc" // lalr1.cc:907
break;
case 26:
-#line 190 "agent_parser.yy" // lalr1.cc:856
+#line 190 "agent_parser.yy" // lalr1.cc:907
{
}
-#line 803 "agent_parser.cc" // lalr1.cc:856
+#line 826 "agent_parser.cc" // lalr1.cc:907
break;
case 29:
-#line 197 "agent_parser.yy" // lalr1.cc:856
+#line 197 "agent_parser.yy" // lalr1.cc:907
{
// List consisting of a single element.
ctx.stack_.back()->add(yystack_[0].value.as< ElementPtr > ());
}
-#line 812 "agent_parser.cc" // lalr1.cc:856
+#line 835 "agent_parser.cc" // lalr1.cc:907
break;
case 30:
-#line 201 "agent_parser.yy" // lalr1.cc:856
+#line 201 "agent_parser.yy" // lalr1.cc:907
{
// List ending with , and a value.
ctx.stack_.back()->add(yystack_[0].value.as< ElementPtr > ());
}
-#line 821 "agent_parser.cc" // lalr1.cc:856
+#line 844 "agent_parser.cc" // lalr1.cc:907
break;
case 31:
-#line 214 "agent_parser.yy" // lalr1.cc:856
+#line 214 "agent_parser.yy" // lalr1.cc:907
{
const std::string& where = ctx.contextName();
const std::string& keyword = yystack_[1].value.as< std::string > ();
error(yystack_[1].location,
"got unexpected keyword \"" + keyword + "\" in " + where + " map.");
}
-#line 832 "agent_parser.cc" // lalr1.cc:856
+#line 855 "agent_parser.cc" // lalr1.cc:907
break;
case 32:
-#line 223 "agent_parser.yy" // lalr1.cc:856
+#line 223 "agent_parser.yy" // lalr1.cc:907
{
// This code is executed when we're about to start parsing
// the content of the map
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.push_back(m);
}
-#line 843 "agent_parser.cc" // lalr1.cc:856
+#line 866 "agent_parser.cc" // lalr1.cc:907
break;
case 33:
-#line 228 "agent_parser.yy" // lalr1.cc:856
+#line 228 "agent_parser.yy" // lalr1.cc:907
{
// map parsing completed. If we ever want to do any wrap up
// (maybe some sanity checking), this would be the best place
// for it.
}
-#line 853 "agent_parser.cc" // lalr1.cc:856
+#line 876 "agent_parser.cc" // lalr1.cc:907
break;
case 42:
-#line 249 "agent_parser.yy" // lalr1.cc:856
+#line 249 "agent_parser.yy" // lalr1.cc:907
{
// Let's create a MapElement that will represent it, add it to the
ctx.stack_.push_back(m);
ctx.enter(ctx.AGENT);
}
-#line 869 "agent_parser.cc" // lalr1.cc:856
+#line 892 "agent_parser.cc" // lalr1.cc:907
break;
case 43:
-#line 259 "agent_parser.yy" // lalr1.cc:856
+#line 259 "agent_parser.yy" // lalr1.cc:907
{
// Ok, we're done with parsing control-agent. Let's take the map
// off the stack.
ctx.stack_.pop_back();
ctx.leave();
}
-#line 880 "agent_parser.cc" // lalr1.cc:856
+#line 903 "agent_parser.cc" // lalr1.cc:907
break;
case 53:
-#line 281 "agent_parser.yy" // lalr1.cc:856
+#line 281 "agent_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORDS);
}
-#line 888 "agent_parser.cc" // lalr1.cc:856
+#line 911 "agent_parser.cc" // lalr1.cc:907
break;
case 54:
-#line 283 "agent_parser.yy" // lalr1.cc:856
+#line 283 "agent_parser.yy" // lalr1.cc:907
{
ElementPtr host(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("http-host", host);
ctx.leave();
}
-#line 898 "agent_parser.cc" // lalr1.cc:856
+#line 921 "agent_parser.cc" // lalr1.cc:907
break;
case 55:
-#line 289 "agent_parser.yy" // lalr1.cc:856
+#line 289 "agent_parser.yy" // lalr1.cc:907
{
ElementPtr prf(new IntElement(yystack_[0].value.as< int64_t > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("http-port", prf);
}
-#line 907 "agent_parser.cc" // lalr1.cc:856
+#line 930 "agent_parser.cc" // lalr1.cc:907
break;
case 56:
-#line 294 "agent_parser.yy" // lalr1.cc:856
+#line 294 "agent_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORDS);
}
-#line 915 "agent_parser.cc" // lalr1.cc:856
+#line 938 "agent_parser.cc" // lalr1.cc:907
break;
case 57:
-#line 296 "agent_parser.yy" // lalr1.cc:856
+#line 296 "agent_parser.yy" // lalr1.cc:907
{
ElementPtr parent = ctx.stack_.back();
ElementPtr user_context = yystack_[0].value.as< ElementPtr > ();
parent->set("user-context", user_context);
ctx.leave();
}
-#line 942 "agent_parser.cc" // lalr1.cc:856
+#line 965 "agent_parser.cc" // lalr1.cc:907
break;
case 58:
-#line 319 "agent_parser.yy" // lalr1.cc:856
+#line 319 "agent_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORDS);
}
-#line 950 "agent_parser.cc" // lalr1.cc:856
+#line 973 "agent_parser.cc" // lalr1.cc:907
break;
case 59:
-#line 321 "agent_parser.yy" // lalr1.cc:856
+#line 321 "agent_parser.yy" // lalr1.cc:907
{
ElementPtr parent = ctx.stack_.back();
ElementPtr user_context(new MapElement(ctx.loc2pos(yystack_[3].location)));
parent->set("user-context", user_context);
ctx.leave();
}
-#line 979 "agent_parser.cc" // lalr1.cc:856
+#line 1002 "agent_parser.cc" // lalr1.cc:907
break;
case 60:
-#line 347 "agent_parser.yy" // lalr1.cc:856
+#line 347 "agent_parser.yy" // lalr1.cc:907
{
ElementPtr l(new ListElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("hooks-libraries", l);
ctx.stack_.push_back(l);
ctx.enter(ctx.HOOKS_LIBRARIES);
}
-#line 990 "agent_parser.cc" // lalr1.cc:856
+#line 1013 "agent_parser.cc" // lalr1.cc:907
break;
case 61:
-#line 352 "agent_parser.yy" // lalr1.cc:856
+#line 352 "agent_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
ctx.leave();
}
-#line 999 "agent_parser.cc" // lalr1.cc:856
+#line 1022 "agent_parser.cc" // lalr1.cc:907
break;
case 66:
-#line 365 "agent_parser.yy" // lalr1.cc:856
+#line 365 "agent_parser.yy" // lalr1.cc:907
{
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->add(m);
ctx.stack_.push_back(m);
}
-#line 1009 "agent_parser.cc" // lalr1.cc:856
+#line 1032 "agent_parser.cc" // lalr1.cc:907
break;
case 67:
-#line 369 "agent_parser.yy" // lalr1.cc:856
+#line 369 "agent_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
}
-#line 1017 "agent_parser.cc" // lalr1.cc:856
+#line 1040 "agent_parser.cc" // lalr1.cc:907
break;
case 73:
-#line 382 "agent_parser.yy" // lalr1.cc:856
+#line 382 "agent_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORDS);
}
-#line 1025 "agent_parser.cc" // lalr1.cc:856
+#line 1048 "agent_parser.cc" // lalr1.cc:907
break;
case 74:
-#line 384 "agent_parser.yy" // lalr1.cc:856
+#line 384 "agent_parser.yy" // lalr1.cc:907
{
ElementPtr lib(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("library", lib);
ctx.leave();
}
-#line 1035 "agent_parser.cc" // lalr1.cc:856
+#line 1058 "agent_parser.cc" // lalr1.cc:907
break;
case 75:
-#line 390 "agent_parser.yy" // lalr1.cc:856
+#line 390 "agent_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORDS);
}
-#line 1043 "agent_parser.cc" // lalr1.cc:856
+#line 1066 "agent_parser.cc" // lalr1.cc:907
break;
case 76:
-#line 392 "agent_parser.yy" // lalr1.cc:856
+#line 392 "agent_parser.yy" // lalr1.cc:907
{
ctx.stack_.back()->set("parameters", yystack_[0].value.as< ElementPtr > ());
ctx.leave();
}
-#line 1052 "agent_parser.cc" // lalr1.cc:856
+#line 1075 "agent_parser.cc" // lalr1.cc:907
break;
case 77:
-#line 400 "agent_parser.yy" // lalr1.cc:856
+#line 400 "agent_parser.yy" // lalr1.cc:907
{
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[2].location)));
ctx.stack_.back()->set("control-sockets", m);
ctx.stack_.push_back(m);
ctx.enter(ctx.CONTROL_SOCKETS);
}
-#line 1063 "agent_parser.cc" // lalr1.cc:856
+#line 1086 "agent_parser.cc" // lalr1.cc:907
break;
case 78:
-#line 405 "agent_parser.yy" // lalr1.cc:856
+#line 405 "agent_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
ctx.leave();
}
-#line 1072 "agent_parser.cc" // lalr1.cc:856
+#line 1095 "agent_parser.cc" // lalr1.cc:907
break;
case 85:
-#line 426 "agent_parser.yy" // lalr1.cc:856
+#line 426 "agent_parser.yy" // lalr1.cc:907
{
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("dhcp4", m);
ctx.stack_.push_back(m);
ctx.enter(ctx.SERVER);
}
-#line 1083 "agent_parser.cc" // lalr1.cc:856
+#line 1106 "agent_parser.cc" // lalr1.cc:907
break;
case 86:
-#line 431 "agent_parser.yy" // lalr1.cc:856
+#line 431 "agent_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
ctx.leave();
}
-#line 1092 "agent_parser.cc" // lalr1.cc:856
+#line 1115 "agent_parser.cc" // lalr1.cc:907
break;
case 87:
-#line 437 "agent_parser.yy" // lalr1.cc:856
+#line 437 "agent_parser.yy" // lalr1.cc:907
{
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("dhcp6", m);
ctx.stack_.push_back(m);
ctx.enter(ctx.SERVER);
}
-#line 1103 "agent_parser.cc" // lalr1.cc:856
+#line 1126 "agent_parser.cc" // lalr1.cc:907
break;
case 88:
-#line 442 "agent_parser.yy" // lalr1.cc:856
+#line 442 "agent_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
ctx.leave();
}
-#line 1112 "agent_parser.cc" // lalr1.cc:856
+#line 1135 "agent_parser.cc" // lalr1.cc:907
break;
case 89:
-#line 448 "agent_parser.yy" // lalr1.cc:856
+#line 448 "agent_parser.yy" // lalr1.cc:907
{
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("d2", m);
ctx.stack_.push_back(m);
ctx.enter(ctx.SERVER);
}
-#line 1123 "agent_parser.cc" // lalr1.cc:856
+#line 1146 "agent_parser.cc" // lalr1.cc:907
break;
case 90:
-#line 453 "agent_parser.yy" // lalr1.cc:856
+#line 453 "agent_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
ctx.leave();
}
-#line 1132 "agent_parser.cc" // lalr1.cc:856
+#line 1155 "agent_parser.cc" // lalr1.cc:907
break;
case 98:
-#line 472 "agent_parser.yy" // lalr1.cc:856
+#line 472 "agent_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORDS);
}
-#line 1140 "agent_parser.cc" // lalr1.cc:856
+#line 1163 "agent_parser.cc" // lalr1.cc:907
break;
case 99:
-#line 474 "agent_parser.yy" // lalr1.cc:856
+#line 474 "agent_parser.yy" // lalr1.cc:907
{
ElementPtr name(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("socket-name", name);
ctx.leave();
}
-#line 1150 "agent_parser.cc" // lalr1.cc:856
+#line 1173 "agent_parser.cc" // lalr1.cc:907
break;
case 100:
-#line 481 "agent_parser.yy" // lalr1.cc:856
+#line 481 "agent_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.SOCKET_TYPE);
}
-#line 1158 "agent_parser.cc" // lalr1.cc:856
+#line 1181 "agent_parser.cc" // lalr1.cc:907
break;
case 101:
-#line 483 "agent_parser.yy" // lalr1.cc:856
+#line 483 "agent_parser.yy" // lalr1.cc:907
{
ctx.stack_.back()->set("socket-type", yystack_[0].value.as< ElementPtr > ());
ctx.leave();
}
-#line 1167 "agent_parser.cc" // lalr1.cc:856
+#line 1190 "agent_parser.cc" // lalr1.cc:907
break;
case 102:
-#line 489 "agent_parser.yy" // lalr1.cc:856
+#line 489 "agent_parser.yy" // lalr1.cc:907
{ yylhs.value.as< ElementPtr > () = ElementPtr(new StringElement("unix", ctx.loc2pos(yystack_[0].location))); }
-#line 1173 "agent_parser.cc" // lalr1.cc:856
+#line 1196 "agent_parser.cc" // lalr1.cc:907
break;
case 103:
-#line 495 "agent_parser.yy" // lalr1.cc:856
+#line 495 "agent_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORDS);
}
-#line 1181 "agent_parser.cc" // lalr1.cc:856
+#line 1204 "agent_parser.cc" // lalr1.cc:907
break;
case 104:
-#line 497 "agent_parser.yy" // lalr1.cc:856
+#line 497 "agent_parser.yy" // lalr1.cc:907
{
ctx.stack_.back()->set("Dhcp4", yystack_[0].value.as< ElementPtr > ());
ctx.leave();
}
-#line 1190 "agent_parser.cc" // lalr1.cc:856
+#line 1213 "agent_parser.cc" // lalr1.cc:907
break;
case 105:
-#line 502 "agent_parser.yy" // lalr1.cc:856
+#line 502 "agent_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORDS);
}
-#line 1198 "agent_parser.cc" // lalr1.cc:856
+#line 1221 "agent_parser.cc" // lalr1.cc:907
break;
case 106:
-#line 504 "agent_parser.yy" // lalr1.cc:856
+#line 504 "agent_parser.yy" // lalr1.cc:907
{
ctx.stack_.back()->set("Dhcp6", yystack_[0].value.as< ElementPtr > ());
ctx.leave();
}
-#line 1207 "agent_parser.cc" // lalr1.cc:856
+#line 1230 "agent_parser.cc" // lalr1.cc:907
break;
case 107:
-#line 509 "agent_parser.yy" // lalr1.cc:856
+#line 509 "agent_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORDS);
}
-#line 1215 "agent_parser.cc" // lalr1.cc:856
+#line 1238 "agent_parser.cc" // lalr1.cc:907
break;
case 108:
-#line 511 "agent_parser.yy" // lalr1.cc:856
+#line 511 "agent_parser.yy" // lalr1.cc:907
{
ctx.stack_.back()->set("DhcpDdns", yystack_[0].value.as< ElementPtr > ());
ctx.leave();
}
-#line 1224 "agent_parser.cc" // lalr1.cc:856
+#line 1247 "agent_parser.cc" // lalr1.cc:907
break;
case 109:
-#line 521 "agent_parser.yy" // lalr1.cc:856
+#line 521 "agent_parser.yy" // lalr1.cc:907
{
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("Logging", m);
ctx.stack_.push_back(m);
ctx.enter(ctx.LOGGING);
}
-#line 1235 "agent_parser.cc" // lalr1.cc:856
+#line 1258 "agent_parser.cc" // lalr1.cc:907
break;
case 110:
-#line 526 "agent_parser.yy" // lalr1.cc:856
+#line 526 "agent_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
ctx.leave();
}
-#line 1244 "agent_parser.cc" // lalr1.cc:856
+#line 1267 "agent_parser.cc" // lalr1.cc:907
break;
case 114:
-#line 543 "agent_parser.yy" // lalr1.cc:856
+#line 543 "agent_parser.yy" // lalr1.cc:907
{
ElementPtr l(new ListElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("loggers", l);
ctx.stack_.push_back(l);
ctx.enter(ctx.LOGGERS);
}
-#line 1255 "agent_parser.cc" // lalr1.cc:856
+#line 1278 "agent_parser.cc" // lalr1.cc:907
break;
case 115:
-#line 548 "agent_parser.yy" // lalr1.cc:856
+#line 548 "agent_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
ctx.leave();
}
-#line 1264 "agent_parser.cc" // lalr1.cc:856
+#line 1287 "agent_parser.cc" // lalr1.cc:907
break;
case 118:
-#line 560 "agent_parser.yy" // lalr1.cc:856
+#line 560 "agent_parser.yy" // lalr1.cc:907
{
ElementPtr l(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->add(l);
ctx.stack_.push_back(l);
}
-#line 1274 "agent_parser.cc" // lalr1.cc:856
+#line 1297 "agent_parser.cc" // lalr1.cc:907
break;
case 119:
-#line 564 "agent_parser.yy" // lalr1.cc:856
+#line 564 "agent_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
}
-#line 1282 "agent_parser.cc" // lalr1.cc:856
+#line 1305 "agent_parser.cc" // lalr1.cc:907
break;
case 129:
-#line 581 "agent_parser.yy" // lalr1.cc:856
+#line 581 "agent_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORDS);
}
-#line 1290 "agent_parser.cc" // lalr1.cc:856
+#line 1313 "agent_parser.cc" // lalr1.cc:907
break;
case 130:
-#line 583 "agent_parser.yy" // lalr1.cc:856
+#line 583 "agent_parser.yy" // lalr1.cc:907
{
ElementPtr name(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("name", name);
ctx.leave();
}
-#line 1300 "agent_parser.cc" // lalr1.cc:856
+#line 1323 "agent_parser.cc" // lalr1.cc:907
break;
case 131:
-#line 589 "agent_parser.yy" // lalr1.cc:856
+#line 589 "agent_parser.yy" // lalr1.cc:907
{
ElementPtr dl(new IntElement(yystack_[0].value.as< int64_t > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("debuglevel", dl);
}
-#line 1309 "agent_parser.cc" // lalr1.cc:856
+#line 1332 "agent_parser.cc" // lalr1.cc:907
break;
case 132:
-#line 594 "agent_parser.yy" // lalr1.cc:856
+#line 594 "agent_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORDS);
}
-#line 1317 "agent_parser.cc" // lalr1.cc:856
+#line 1340 "agent_parser.cc" // lalr1.cc:907
break;
case 133:
-#line 596 "agent_parser.yy" // lalr1.cc:856
+#line 596 "agent_parser.yy" // lalr1.cc:907
{
ElementPtr sev(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("severity", sev);
ctx.leave();
}
-#line 1327 "agent_parser.cc" // lalr1.cc:856
+#line 1350 "agent_parser.cc" // lalr1.cc:907
break;
case 134:
-#line 602 "agent_parser.yy" // lalr1.cc:856
+#line 602 "agent_parser.yy" // lalr1.cc:907
{
ElementPtr l(new ListElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("output_options", l);
ctx.stack_.push_back(l);
ctx.enter(ctx.OUTPUT_OPTIONS);
}
-#line 1338 "agent_parser.cc" // lalr1.cc:856
+#line 1361 "agent_parser.cc" // lalr1.cc:907
break;
case 135:
-#line 607 "agent_parser.yy" // lalr1.cc:856
+#line 607 "agent_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
ctx.leave();
}
-#line 1347 "agent_parser.cc" // lalr1.cc:856
+#line 1370 "agent_parser.cc" // lalr1.cc:907
break;
case 138:
-#line 616 "agent_parser.yy" // lalr1.cc:856
+#line 616 "agent_parser.yy" // lalr1.cc:907
{
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->add(m);
ctx.stack_.push_back(m);
}
-#line 1357 "agent_parser.cc" // lalr1.cc:856
+#line 1380 "agent_parser.cc" // lalr1.cc:907
break;
case 139:
-#line 620 "agent_parser.yy" // lalr1.cc:856
+#line 620 "agent_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
}
-#line 1365 "agent_parser.cc" // lalr1.cc:856
+#line 1388 "agent_parser.cc" // lalr1.cc:907
break;
case 146:
-#line 634 "agent_parser.yy" // lalr1.cc:856
+#line 634 "agent_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORDS);
}
-#line 1373 "agent_parser.cc" // lalr1.cc:856
+#line 1396 "agent_parser.cc" // lalr1.cc:907
break;
case 147:
-#line 636 "agent_parser.yy" // lalr1.cc:856
+#line 636 "agent_parser.yy" // lalr1.cc:907
{
ElementPtr sev(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("output", sev);
ctx.leave();
}
-#line 1383 "agent_parser.cc" // lalr1.cc:856
+#line 1406 "agent_parser.cc" // lalr1.cc:907
break;
case 148:
-#line 642 "agent_parser.yy" // lalr1.cc:856
+#line 642 "agent_parser.yy" // lalr1.cc:907
{
ElementPtr flush(new BoolElement(yystack_[0].value.as< bool > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("flush", flush);
}
-#line 1392 "agent_parser.cc" // lalr1.cc:856
+#line 1415 "agent_parser.cc" // lalr1.cc:907
break;
case 149:
-#line 647 "agent_parser.yy" // lalr1.cc:856
+#line 647 "agent_parser.yy" // lalr1.cc:907
{
ElementPtr maxsize(new IntElement(yystack_[0].value.as< int64_t > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("maxsize", maxsize);
}
-#line 1401 "agent_parser.cc" // lalr1.cc:856
+#line 1424 "agent_parser.cc" // lalr1.cc:907
break;
case 150:
-#line 652 "agent_parser.yy" // lalr1.cc:856
+#line 652 "agent_parser.yy" // lalr1.cc:907
{
ElementPtr maxver(new IntElement(yystack_[0].value.as< int64_t > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("maxver", maxver);
}
-#line 1410 "agent_parser.cc" // lalr1.cc:856
+#line 1433 "agent_parser.cc" // lalr1.cc:907
break;
-#line 1414 "agent_parser.cc" // lalr1.cc:856
+#line 1437 "agent_parser.cc" // lalr1.cc:907
default:
break;
}
}
+#if YY_EXCEPTIONS
catch (const syntax_error& yyexc)
{
error (yyexc);
YYERROR;
}
+#endif // YY_EXCEPTIONS
YY_SYMBOL_PRINT ("-> $$ =", yylhs);
yypop_ (yylen);
yylen = 0;
YY_STACK_PRINT ();
// Shift the result of the reduction.
- yypush_ (YY_NULLPTR, yylhs);
+ yypush_ (YY_NULLPTR, YY_MOVE (yylhs));
}
goto yynewstate;
// Shift the error token.
error_token.state = yyn;
- yypush_ ("Shifting", error_token);
+ yypush_ ("Shifting", YY_MOVE (error_token));
}
goto yynewstate;
return yyresult;
}
+#if YY_EXCEPTIONS
catch (...)
{
YYCDEBUG << "Exception caught: cleaning lookahead and stack\n";
// Do not try to display the values of the reclaimed symbols,
- // as their printer might throw an exception.
+ // as their printers might throw an exception.
if (!yyla.empty ())
yy_destroy_ (YY_NULLPTR, yyla);
}
throw;
}
+#endif // YY_EXCEPTIONS
}
void
const signed char AgentParser::yytable_ninf_ = -1;
- const short int
+ const short
AgentParser::yypact_[] =
{
59, -68, -68, -68, 6, 8, 9, 34, -68, -68,
-68, -67, -68, -68, -68, -68, -68
};
- const short int
+ const short
AgentParser::yydefgoto_[] =
{
-1, 4, 5, 6, 7, 23, 27, 16, 17, 18,
199
};
- const short int
+ const short
AgentParser::yycheck_[] =
{
26, 27, 27, 27, 24, 10, 0, 11, 12, 13,
};
#if AGENT_DEBUG
- const unsigned short int
+ const unsigned short
AgentParser::yyrline_[] =
{
0, 114, 114, 114, 115, 115, 116, 116, 124, 124,
#endif // AGENT_DEBUG
-#line 14 "agent_parser.yy" // lalr1.cc:1163
+#line 14 "agent_parser.yy" // lalr1.cc:1218
} } // isc::agent
-#line 1981 "agent_parser.cc" // lalr1.cc:1163
-#line 657 "agent_parser.yy" // lalr1.cc:1164
+#line 2008 "agent_parser.cc" // lalr1.cc:1218
+#line 657 "agent_parser.yy" // lalr1.cc:1219
void
-// A Bison parser, made by GNU Bison 3.0.5.
+// A Bison parser, made by GNU Bison 3.2.1.
// Skeleton interface for Bison LALR(1) parsers in C++
// This special exception was added by the Free Software Foundation in
// version 2.2 of Bison.
+
/**
** \file agent_parser.h
** Define the isc::agent::parser class.
// C++ LALR(1) parser skeleton written by Akim Demaille.
+// Undocumented macros, especially those whose name start with YY_,
+// are private implementation details. Do not rely on them.
+
#ifndef YY_AGENT_AGENT_PARSER_H_INCLUDED
# define YY_AGENT_AGENT_PARSER_H_INCLUDED
// // "%code requires" blocks.
-#line 17 "agent_parser.yy" // lalr1.cc:379
+#line 17 "agent_parser.yy" // lalr1.cc:404
#include <string>
#include <cc/data.h>
using namespace isc::data;
using namespace std;
-#line 55 "agent_parser.h" // lalr1.cc:379
+#line 59 "agent_parser.h" // lalr1.cc:404
# include <cassert>
# include <cstdlib> // std::abort
# include <stdexcept>
# include <string>
# include <vector>
-# include "stack.hh"
+
+// Support move semantics when possible.
+#if defined __cplusplus && 201103L <= __cplusplus
+# define YY_MOVE std::move
+# define YY_MOVE_OR_COPY move
+# define YY_MOVE_REF(Type) Type&&
+# define YY_RVREF(Type) Type&&
+# define YY_COPY(Type) Type
+#else
+# define YY_MOVE
+# define YY_MOVE_OR_COPY copy
+# define YY_MOVE_REF(Type) Type&
+# define YY_RVREF(Type) const Type&
+# define YY_COPY(Type) const Type&
+#endif
# include "location.hh"
#include <typeinfo>
#ifndef YYASSERT
# define YY_ATTRIBUTE_UNUSED YY_ATTRIBUTE ((__unused__))
#endif
-#if !defined _Noreturn \
- && (!defined __STDC_VERSION__ || __STDC_VERSION__ < 201112)
-# if defined _MSC_VER && 1200 <= _MSC_VER
-# define _Noreturn __declspec (noreturn)
-# else
-# define _Noreturn YY_ATTRIBUTE ((__noreturn__))
-# endif
-#endif
-
/* Suppress unused-variable warnings by "using" E. */
#if ! defined lint || defined __GNUC__
# define YYUSE(E) ((void) (E))
# define YYUSE(E) /* empty */
#endif
-#if defined __GNUC__ && 407 <= __GNUC__ * 100 + __GNUC_MINOR__
+#if defined __GNUC__ && ! defined __ICC && 407 <= __GNUC__ * 100 + __GNUC_MINOR__
/* Suppress an incorrect diagnostic about yylval being uninitialized. */
# define YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN \
_Pragma ("GCC diagnostic push") \
# define YY_INITIAL_VALUE(Value) /* Nothing. */
#endif
+# ifndef YY_NULLPTR
+# if defined __cplusplus
+# if 201103L <= __cplusplus
+# define YY_NULLPTR nullptr
+# else
+# define YY_NULLPTR 0
+# endif
+# else
+# define YY_NULLPTR ((void*)0)
+# endif
+# endif
+
/* Debug traces. */
#ifndef AGENT_DEBUG
# if defined YYDEBUG
# endif /* ! defined YYDEBUG */
#endif /* ! defined AGENT_DEBUG */
-#line 14 "agent_parser.yy" // lalr1.cc:379
+#line 14 "agent_parser.yy" // lalr1.cc:404
namespace isc { namespace agent {
-#line 140 "agent_parser.h" // lalr1.cc:379
+#line 161 "agent_parser.h" // lalr1.cc:404
+
+ /// A stack with random access from its top.
+ template <typename T, typename S = std::vector<T> >
+ class stack
+ {
+ public:
+ // Hide our reversed order.
+ typedef typename S::reverse_iterator iterator;
+ typedef typename S::const_reverse_iterator const_iterator;
+ typedef typename S::size_type size_type;
+
+ stack (size_type n = 200)
+ : seq_ (n)
+ {}
+
+ /// Random access.
+ ///
+ /// Index 0 returns the topmost element.
+ T&
+ operator[] (size_type i)
+ {
+ return seq_[size () - 1 - i];
+ }
+
+ /// Random access.
+ ///
+ /// Index 0 returns the topmost element.
+ T&
+ operator[] (int i)
+ {
+ return operator[] (size_type (i));
+ }
+
+ /// Random access.
+ ///
+ /// Index 0 returns the topmost element.
+ const T&
+ operator[] (size_type i) const
+ {
+ return seq_[size () - 1 - i];
+ }
+
+ /// Random access.
+ ///
+ /// Index 0 returns the topmost element.
+ const T&
+ operator[] (int i) const
+ {
+ return operator[] (size_type (i));
+ }
+
+ /// Steal the contents of \a t.
+ ///
+ /// Close to move-semantics.
+ void
+ push (YY_MOVE_REF (T) t)
+ {
+ seq_.push_back (T ());
+ operator[](0).move (t);
+ }
+
+ void
+ pop (int n = 1)
+ {
+ for (; 0 < n; --n)
+ seq_.pop_back ();
+ }
+
+ void
+ clear ()
+ {
+ seq_.clear ();
+ }
+
+ size_type
+ size () const
+ {
+ return seq_.size ();
+ }
+
+ const_iterator
+ begin () const
+ {
+ return seq_.rbegin ();
+ }
+
+ const_iterator
+ end () const
+ {
+ return seq_.rend ();
+ }
+
+ private:
+ stack (const stack&);
+ stack& operator= (const stack&);
+ /// The wrapped container.
+ S seq_;
+ };
+
+ /// Present a slice of the top of a stack.
+ template <typename T, typename S = stack<T> >
+ class slice
+ {
+ public:
+ slice (const S& stack, int range)
+ : stack_ (stack)
+ , range_ (range)
+ {}
+
+ const T&
+ operator[] (int i) const
+ {
+ return stack_[range_ - i];
+ }
+
+ private:
+ const S& stack_;
+ int range_;
+ };
/// Empty construction.
variant ()
- : yytypeid_ (YY_NULLPTR)
+ : yybuffer_ ()
+ , yytypeid_ (YY_NULLPTR)
{}
/// Construct and fill.
template <typename T>
- variant (const T& t)
+ variant (YY_RVREF (T) t)
: yytypeid_ (&typeid (T))
{
YYASSERT (sizeof (T) <= S);
- new (yyas_<T> ()) T (t);
+ new (yyas_<T> ()) T (YY_MOVE (t));
}
/// Destruction, allowed only if empty.
/// Instantiate an empty \a T in here.
template <typename T>
T&
- build ()
+ emplace ()
{
YYASSERT (!yytypeid_);
YYASSERT (sizeof (T) <= S);
yytypeid_ = & typeid (T);
- return *new (yyas_<T> ()) T;
+ return *new (yyas_<T> ()) T ();
}
+# if defined __cplusplus && 201103L <= __cplusplus
+ /// Instantiate a \a T in here from \a t.
+ template <typename T, typename U>
+ T&
+ emplace (U&& u)
+ {
+ YYASSERT (!yytypeid_);
+ YYASSERT (sizeof (T) <= S);
+ yytypeid_ = & typeid (T);
+ return *new (yyas_<T> ()) T (std::forward <U>(u));
+ }
+# else
/// Instantiate a \a T in here from \a t.
template <typename T>
T&
- build (const T& t)
+ emplace (const T& t)
{
YYASSERT (!yytypeid_);
YYASSERT (sizeof (T) <= S);
yytypeid_ = & typeid (T);
return *new (yyas_<T> ()) T (t);
}
+# endif
+
+ /// Instantiate an empty \a T in here.
+ /// Obsolete, use emplace.
+ template <typename T>
+ T&
+ build ()
+ {
+ return emplace<T> ();
+ }
+
+ /// Instantiate a \a T in here from \a t.
+ /// Obsolete, use emplace.
+ template <typename T>
+ T&
+ build (const T& t)
+ {
+ return emplace<T> (t);
+ }
/// Accessor to a built \a T.
template <typename T>
T&
as ()
{
+ YYASSERT (yytypeid_);
YYASSERT (*yytypeid_ == typeid (T));
YYASSERT (sizeof (T) <= S);
return *yyas_<T> ();
const T&
as () const
{
+ YYASSERT (yytypeid_);
YYASSERT (*yytypeid_ == typeid (T));
YYASSERT (sizeof (T) <= S);
return *yyas_<T> ();
/// Both variants must be built beforehand, because swapping the actual
/// data requires reading it (with as()), and this is not possible on
/// unconstructed variants: it would require some dynamic testing, which
- /// should not be the variant's responsability.
+ /// should not be the variant's responsibility.
/// Swapping between built and (possibly) non-built is done with
/// variant::move ().
template <typename T>
void
move (self_type& other)
{
- build<T> ();
+# if defined __cplusplus && 201103L <= __cplusplus
+ emplace<T> (std::move (other.as<T> ()));
+# else
+ emplace<T> ();
swap<T> (other);
+# endif
other.destroy<T> ();
}
+# if defined __cplusplus && 201103L <= __cplusplus
+ /// Move the content of \a other to this.
+ template <typename T>
+ void
+ move (self_type&& other)
+ {
+ emplace<T> (std::move (other.as<T> ()));
+ other.destroy<T> ();
+ }
+#endif
+
/// Copy the content of \a other to this.
template <typename T>
void
copy (const self_type& other)
{
- build<T> (other.as<T> ());
+ emplace<T> (other.as<T> ());
}
/// Destroy the stored \a T.
private:
/// Prohibit blind copies.
- self_type& operator=(const self_type&);
+ self_type& operator= (const self_type&);
variant (const self_type&);
/// Accessor to raw memory as \a T.
// value
// map_value
// socket_type_value
- char dummy1[sizeof(ElementPtr)];
+ char dummy1[sizeof (ElementPtr)];
// "boolean"
- char dummy2[sizeof(bool)];
+ char dummy2[sizeof (bool)];
// "floating point"
- char dummy3[sizeof(double)];
+ char dummy3[sizeof (double)];
// "integer"
- char dummy4[sizeof(int64_t)];
+ char dummy4[sizeof (int64_t)];
// "constant string"
- char dummy5[sizeof(std::string)];
+ char dummy5[sizeof (std::string)];
};
/// Symbol semantic values.
- typedef variant<sizeof(union_type)> semantic_type;
+ typedef variant<sizeof (union_type)> semantic_type;
#else
typedef AGENT_STYPE semantic_type;
#endif
/// A complete symbol.
///
/// Expects its Base type to provide access to the symbol type
- /// via type_get().
+ /// via type_get ().
///
/// Provide access to semantic value and location.
template <typename Base>
/// Default constructor.
basic_symbol ();
- /// Copy constructor.
- basic_symbol (const basic_symbol& other);
-
- /// Constructor for valueless symbols, and symbols from each type.
-
- basic_symbol (typename Base::kind_type t, const location_type& l);
-
- basic_symbol (typename Base::kind_type t, const ElementPtr v, const location_type& l);
+ /// Move or copy constructor.
+ basic_symbol (YY_RVREF (basic_symbol) other);
- basic_symbol (typename Base::kind_type t, const bool v, const location_type& l);
-
- basic_symbol (typename Base::kind_type t, const double v, const location_type& l);
-
- basic_symbol (typename Base::kind_type t, const int64_t v, const location_type& l);
-
- basic_symbol (typename Base::kind_type t, const std::string v, const location_type& l);
+ /// Constructor for valueless symbols, and symbols from each type.
+ basic_symbol (typename Base::kind_type t, YY_RVREF (location_type) l);
+ basic_symbol (typename Base::kind_type t, YY_RVREF (ElementPtr) v, YY_RVREF (location_type) l);
+ basic_symbol (typename Base::kind_type t, YY_RVREF (bool) v, YY_RVREF (location_type) l);
+ basic_symbol (typename Base::kind_type t, YY_RVREF (double) v, YY_RVREF (location_type) l);
+ basic_symbol (typename Base::kind_type t, YY_RVREF (int64_t) v, YY_RVREF (location_type) l);
+ basic_symbol (typename Base::kind_type t, YY_RVREF (std::string) v, YY_RVREF (location_type) l);
- /// Constructor for symbols with semantic value.
- basic_symbol (typename Base::kind_type t,
- const semantic_type& v,
- const location_type& l);
/// Destroy the symbol.
~basic_symbol ();
location_type location;
private:
+#if !defined __cplusplus || __cplusplus < 201103L
/// Assignment operator.
basic_symbol& operator= (const basic_symbol& other);
+#endif
};
/// Type access provider for token (enum) based symbols.
/// "External" symbols: returned by the scanner.
typedef basic_symbol<by_type> symbol_type;
+ /// Build a parser object.
+ AgentParser (isc::agent::ParserContext& ctx_yyarg);
+ virtual ~AgentParser ();
+
+ /// Parse. An alias for parse ().
+ /// \returns 0 iff parsing succeeded.
+ int operator() ();
+
+ /// Parse.
+ /// \returns 0 iff parsing succeeded.
+ virtual int parse ();
+
+#if AGENT_DEBUG
+ /// The current debugging stream.
+ std::ostream& debug_stream () const YY_ATTRIBUTE_PURE;
+ /// Set the current debugging stream.
+ void set_debug_stream (std::ostream &);
+
+ /// Type for debugging levels.
+ typedef int debug_level_type;
+ /// The current debugging level.
+ debug_level_type debug_level () const YY_ATTRIBUTE_PURE;
+ /// Set the current debugging level.
+ void set_debug_level (debug_level_type l);
+#endif
+
+ /// Report a syntax error.
+ /// \param loc where the syntax error is found.
+ /// \param msg a description of the syntax error.
+ virtual void error (const location_type& loc, const std::string& msg);
+
+ /// Report a syntax error.
+ void error (const syntax_error& err);
+
// Symbol constructors declarations.
- static inline
+ static
symbol_type
- make_END (const location_type& l);
+ make_END (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_COMMA (const location_type& l);
+ make_COMMA (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_COLON (const location_type& l);
+ make_COLON (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_LSQUARE_BRACKET (const location_type& l);
+ make_LSQUARE_BRACKET (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_RSQUARE_BRACKET (const location_type& l);
+ make_RSQUARE_BRACKET (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_LCURLY_BRACKET (const location_type& l);
+ make_LCURLY_BRACKET (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_RCURLY_BRACKET (const location_type& l);
+ make_RCURLY_BRACKET (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_NULL_TYPE (const location_type& l);
+ make_NULL_TYPE (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_CONTROL_AGENT (const location_type& l);
+ make_CONTROL_AGENT (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_HTTP_HOST (const location_type& l);
+ make_HTTP_HOST (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_HTTP_PORT (const location_type& l);
+ make_HTTP_PORT (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_USER_CONTEXT (const location_type& l);
+ make_USER_CONTEXT (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_COMMENT (const location_type& l);
+ make_COMMENT (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_CONTROL_SOCKETS (const location_type& l);
+ make_CONTROL_SOCKETS (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_DHCP4_SERVER (const location_type& l);
+ make_DHCP4_SERVER (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_DHCP6_SERVER (const location_type& l);
+ make_DHCP6_SERVER (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_D2_SERVER (const location_type& l);
+ make_D2_SERVER (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_SOCKET_NAME (const location_type& l);
+ make_SOCKET_NAME (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_SOCKET_TYPE (const location_type& l);
+ make_SOCKET_TYPE (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_UNIX (const location_type& l);
+ make_UNIX (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_HOOKS_LIBRARIES (const location_type& l);
+ make_HOOKS_LIBRARIES (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_LIBRARY (const location_type& l);
+ make_LIBRARY (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_PARAMETERS (const location_type& l);
+ make_PARAMETERS (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_LOGGING (const location_type& l);
+ make_LOGGING (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_LOGGERS (const location_type& l);
+ make_LOGGERS (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_NAME (const location_type& l);
+ make_NAME (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_OUTPUT_OPTIONS (const location_type& l);
+ make_OUTPUT_OPTIONS (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_OUTPUT (const location_type& l);
+ make_OUTPUT (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_DEBUGLEVEL (const location_type& l);
+ make_DEBUGLEVEL (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_SEVERITY (const location_type& l);
+ make_SEVERITY (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_FLUSH (const location_type& l);
+ make_FLUSH (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_MAXSIZE (const location_type& l);
+ make_MAXSIZE (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_MAXVER (const location_type& l);
+ make_MAXVER (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_DHCP4 (const location_type& l);
+ make_DHCP4 (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_DHCP6 (const location_type& l);
+ make_DHCP6 (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_DHCPDDNS (const location_type& l);
+ make_DHCPDDNS (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_START_JSON (const location_type& l);
+ make_START_JSON (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_START_AGENT (const location_type& l);
+ make_START_AGENT (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_START_SUB_AGENT (const location_type& l);
+ make_START_SUB_AGENT (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_STRING (const std::string& v, const location_type& l);
+ make_STRING (YY_COPY (std::string) v, YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_INTEGER (const int64_t& v, const location_type& l);
+ make_INTEGER (YY_COPY (int64_t) v, YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_FLOAT (const double& v, const location_type& l);
+ make_FLOAT (YY_COPY (double) v, YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_BOOLEAN (const bool& v, const location_type& l);
-
-
- /// Build a parser object.
- AgentParser (isc::agent::ParserContext& ctx_yyarg);
- virtual ~AgentParser ();
-
- /// Parse.
- /// \returns 0 iff parsing succeeded.
- virtual int parse ();
-
-#if AGENT_DEBUG
- /// The current debugging stream.
- std::ostream& debug_stream () const YY_ATTRIBUTE_PURE;
- /// Set the current debugging stream.
- void set_debug_stream (std::ostream &);
-
- /// Type for debugging levels.
- typedef int debug_level_type;
- /// The current debugging level.
- debug_level_type debug_level () const YY_ATTRIBUTE_PURE;
- /// Set the current debugging level.
- void set_debug_level (debug_level_type l);
-#endif
+ make_BOOLEAN (YY_COPY (bool) v, YY_COPY (location_type) l);
- /// Report a syntax error.
- /// \param loc where the syntax error is found.
- /// \param msg a description of the syntax error.
- virtual void error (const location_type& loc, const std::string& msg);
- /// Report a syntax error.
- void error (const syntax_error& err);
private:
/// This class is not copyable.
// Tables.
// YYPACT[STATE-NUM] -- Index in YYTABLE of the portion describing
// STATE-NUM.
- static const short int yypact_[];
+ static const short yypact_[];
// YYDEFACT[STATE-NUM] -- Default reduction number in state STATE-NUM.
// Performed when YYTABLE does not specify something else to do. Zero
static const signed char yypgoto_[];
// YYDEFGOTO[NTERM-NUM].
- static const short int yydefgoto_[];
+ static const short yydefgoto_[];
// YYTABLE[YYPACT[STATE-NUM]] -- What to do in state STATE-NUM. If
// positive, shift that token. If negative, reduce the rule whose
// number is the opposite. If YYTABLE_NINF, syntax error.
static const unsigned char yytable_[];
- static const short int yycheck_[];
+ static const short yycheck_[];
// YYSTOS[STATE-NUM] -- The (internal number of the) accessing
// symbol of state STATE-NUM.
static const char* const yytname_[];
#if AGENT_DEBUG
// YYRLINE[YYN] -- Source line where rule number YYN was defined.
- static const unsigned short int yyrline_[];
+ static const unsigned short yyrline_[];
/// Report on the debug stream that the rule \a r is going to be reduced.
virtual void yy_reduce_print_ (int r);
/// Print the state stack on the debug stream.
virtual void yystack_print_ ();
- // Debugging.
+ /// Debugging level.
int yydebug_;
+ /// Debug stream.
std::ostream* yycdebug_;
/// \brief Display a symbol type, value and location.
typedef basic_symbol<by_state> super_type;
/// Construct an empty symbol.
stack_symbol_type ();
- /// Copy construct.
- stack_symbol_type (const stack_symbol_type& that);
+ /// Move or copy construction.
+ stack_symbol_type (YY_RVREF (stack_symbol_type) that);
/// Steal the contents from \a sym to build this.
- stack_symbol_type (state_type s, symbol_type& sym);
- /// Assignment, needed by push_back.
- stack_symbol_type& operator= (const stack_symbol_type& that);
+ stack_symbol_type (state_type s, YY_MOVE_REF (symbol_type) sym);
+#if !defined __cplusplus || __cplusplus < 201103L
+ /// Assignment, needed by push_back by some old implementations.
+ /// Moves the contents of that.
+ stack_symbol_type& operator= (stack_symbol_type& that);
+#endif
};
/// Stack type.
/// Push a new state on the stack.
/// \param m a debug message to display
/// if null, no trace is output.
- /// \param s the symbol
+ /// \param sym the symbol
/// \warning the contents of \a s.value is stolen.
- void yypush_ (const char* m, stack_symbol_type& s);
+ void yypush_ (const char* m, YY_MOVE_REF (stack_symbol_type) sym);
/// Push a new look ahead token on the state on the stack.
/// \param m a debug message to display
/// if null, no trace is output.
/// \param s the state
/// \param sym the symbol (for its value and location).
- /// \warning the contents of \a s.value is stolen.
- void yypush_ (const char* m, state_type s, symbol_type& sym);
+ /// \warning the contents of \a sym.value is stolen.
+ void yypush_ (const char* m, state_type s, YY_MOVE_REF (symbol_type) sym);
- /// Pop \a n symbols the three stacks.
- void yypop_ (unsigned n = 1);
+ /// Pop \a n symbols from the stack.
+ void yypop_ (int n = 1);
/// Constants.
enum
template <typename Base>
AgentParser::basic_symbol<Base>::basic_symbol ()
: value ()
+ , location ()
{}
template <typename Base>
- AgentParser::basic_symbol<Base>::basic_symbol (const basic_symbol& other)
- : Base (other)
+ AgentParser::basic_symbol<Base>::basic_symbol (YY_RVREF (basic_symbol) other)
+ : Base (YY_MOVE (other))
, value ()
- , location (other.location)
+ , location (YY_MOVE (other.location))
{
switch (other.type_get ())
{
case 53: // value
case 56: // map_value
case 107: // socket_type_value
- value.copy< ElementPtr > (other.value);
+ value.YY_MOVE_OR_COPY< ElementPtr > (YY_MOVE (other.value));
break;
case 44: // "boolean"
- value.copy< bool > (other.value);
+ value.YY_MOVE_OR_COPY< bool > (YY_MOVE (other.value));
break;
case 43: // "floating point"
- value.copy< double > (other.value);
+ value.YY_MOVE_OR_COPY< double > (YY_MOVE (other.value));
break;
case 42: // "integer"
- value.copy< int64_t > (other.value);
+ value.YY_MOVE_OR_COPY< int64_t > (YY_MOVE (other.value));
break;
case 41: // "constant string"
- value.copy< std::string > (other.value);
+ value.YY_MOVE_OR_COPY< std::string > (YY_MOVE (other.value));
break;
default:
}
- template <typename Base>
- AgentParser::basic_symbol<Base>::basic_symbol (typename Base::kind_type t, const semantic_type& v, const location_type& l)
- : Base (t)
- , value ()
- , location (l)
- {
- (void) v;
- switch (this->type_get ())
- {
- case 53: // value
- case 56: // map_value
- case 107: // socket_type_value
- value.copy< ElementPtr > (v);
- break;
-
- case 44: // "boolean"
- value.copy< bool > (v);
- break;
-
- case 43: // "floating point"
- value.copy< double > (v);
- break;
-
- case 42: // "integer"
- value.copy< int64_t > (v);
- break;
-
- case 41: // "constant string"
- value.copy< std::string > (v);
- break;
-
- default:
- break;
- }
-}
-
// Implementation of basic_symbol constructor for each type.
-
template <typename Base>
- AgentParser::basic_symbol<Base>::basic_symbol (typename Base::kind_type t, const location_type& l)
+ AgentParser::basic_symbol<Base>::basic_symbol (typename Base::kind_type t, YY_RVREF (location_type) l)
: Base (t)
- , value ()
- , location (l)
+ , location (YY_MOVE (l))
{}
template <typename Base>
- AgentParser::basic_symbol<Base>::basic_symbol (typename Base::kind_type t, const ElementPtr v, const location_type& l)
+ AgentParser::basic_symbol<Base>::basic_symbol (typename Base::kind_type t, YY_RVREF (ElementPtr) v, YY_RVREF (location_type) l)
: Base (t)
- , value (v)
- , location (l)
+ , value (YY_MOVE (v))
+ , location (YY_MOVE (l))
{}
template <typename Base>
- AgentParser::basic_symbol<Base>::basic_symbol (typename Base::kind_type t, const bool v, const location_type& l)
+ AgentParser::basic_symbol<Base>::basic_symbol (typename Base::kind_type t, YY_RVREF (bool) v, YY_RVREF (location_type) l)
: Base (t)
- , value (v)
- , location (l)
+ , value (YY_MOVE (v))
+ , location (YY_MOVE (l))
{}
template <typename Base>
- AgentParser::basic_symbol<Base>::basic_symbol (typename Base::kind_type t, const double v, const location_type& l)
+ AgentParser::basic_symbol<Base>::basic_symbol (typename Base::kind_type t, YY_RVREF (double) v, YY_RVREF (location_type) l)
: Base (t)
- , value (v)
- , location (l)
+ , value (YY_MOVE (v))
+ , location (YY_MOVE (l))
{}
template <typename Base>
- AgentParser::basic_symbol<Base>::basic_symbol (typename Base::kind_type t, const int64_t v, const location_type& l)
+ AgentParser::basic_symbol<Base>::basic_symbol (typename Base::kind_type t, YY_RVREF (int64_t) v, YY_RVREF (location_type) l)
: Base (t)
- , value (v)
- , location (l)
+ , value (YY_MOVE (v))
+ , location (YY_MOVE (l))
{}
template <typename Base>
- AgentParser::basic_symbol<Base>::basic_symbol (typename Base::kind_type t, const std::string v, const location_type& l)
+ AgentParser::basic_symbol<Base>::basic_symbol (typename Base::kind_type t, YY_RVREF (std::string) v, YY_RVREF (location_type) l)
: Base (t)
- , value (v)
- , location (l)
+ , value (YY_MOVE (v))
+ , location (YY_MOVE (l))
{}
+
template <typename Base>
AgentParser::basic_symbol<Base>::~basic_symbol ()
{
case 53: // value
case 56: // map_value
case 107: // socket_type_value
- value.move< ElementPtr > (s.value);
+ value.move< ElementPtr > (YY_MOVE (s.value));
break;
case 44: // "boolean"
- value.move< bool > (s.value);
+ value.move< bool > (YY_MOVE (s.value));
break;
case 43: // "floating point"
- value.move< double > (s.value);
+ value.move< double > (YY_MOVE (s.value));
break;
case 42: // "integer"
- value.move< int64_t > (s.value);
+ value.move< int64_t > (YY_MOVE (s.value));
break;
case 41: // "constant string"
- value.move< std::string > (s.value);
+ value.move< std::string > (YY_MOVE (s.value));
break;
default:
break;
}
- location = s.location;
+ location = YY_MOVE (s.location);
}
// by_type.
// YYTOKNUM[NUM] -- (External) token number corresponding to the
// (internal) symbol number NUM (which must be that of a token). */
static
- const unsigned short int
+ const unsigned short
yytoken_number_[] =
{
0, 256, 257, 258, 259, 260, 261, 262, 263, 264,
};
return static_cast<token_type> (yytoken_number_[type]);
}
+
// Implementation of make_symbol for each symbol type.
+ inline
AgentParser::symbol_type
- AgentParser::make_END (const location_type& l)
+ AgentParser::make_END (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_END, l);
+ return symbol_type (token::TOKEN_END, YY_MOVE (l));
}
+ inline
AgentParser::symbol_type
- AgentParser::make_COMMA (const location_type& l)
+ AgentParser::make_COMMA (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_COMMA, l);
+ return symbol_type (token::TOKEN_COMMA, YY_MOVE (l));
}
+ inline
AgentParser::symbol_type
- AgentParser::make_COLON (const location_type& l)
+ AgentParser::make_COLON (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_COLON, l);
+ return symbol_type (token::TOKEN_COLON, YY_MOVE (l));
}
+ inline
AgentParser::symbol_type
- AgentParser::make_LSQUARE_BRACKET (const location_type& l)
+ AgentParser::make_LSQUARE_BRACKET (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_LSQUARE_BRACKET, l);
+ return symbol_type (token::TOKEN_LSQUARE_BRACKET, YY_MOVE (l));
}
+ inline
AgentParser::symbol_type
- AgentParser::make_RSQUARE_BRACKET (const location_type& l)
+ AgentParser::make_RSQUARE_BRACKET (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_RSQUARE_BRACKET, l);
+ return symbol_type (token::TOKEN_RSQUARE_BRACKET, YY_MOVE (l));
}
+ inline
AgentParser::symbol_type
- AgentParser::make_LCURLY_BRACKET (const location_type& l)
+ AgentParser::make_LCURLY_BRACKET (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_LCURLY_BRACKET, l);
+ return symbol_type (token::TOKEN_LCURLY_BRACKET, YY_MOVE (l));
}
+ inline
AgentParser::symbol_type
- AgentParser::make_RCURLY_BRACKET (const location_type& l)
+ AgentParser::make_RCURLY_BRACKET (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_RCURLY_BRACKET, l);
+ return symbol_type (token::TOKEN_RCURLY_BRACKET, YY_MOVE (l));
}
+ inline
AgentParser::symbol_type
- AgentParser::make_NULL_TYPE (const location_type& l)
+ AgentParser::make_NULL_TYPE (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_NULL_TYPE, l);
+ return symbol_type (token::TOKEN_NULL_TYPE, YY_MOVE (l));
}
+ inline
AgentParser::symbol_type
- AgentParser::make_CONTROL_AGENT (const location_type& l)
+ AgentParser::make_CONTROL_AGENT (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_CONTROL_AGENT, l);
+ return symbol_type (token::TOKEN_CONTROL_AGENT, YY_MOVE (l));
}
+ inline
AgentParser::symbol_type
- AgentParser::make_HTTP_HOST (const location_type& l)
+ AgentParser::make_HTTP_HOST (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_HTTP_HOST, l);
+ return symbol_type (token::TOKEN_HTTP_HOST, YY_MOVE (l));
}
+ inline
AgentParser::symbol_type
- AgentParser::make_HTTP_PORT (const location_type& l)
+ AgentParser::make_HTTP_PORT (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_HTTP_PORT, l);
+ return symbol_type (token::TOKEN_HTTP_PORT, YY_MOVE (l));
}
+ inline
AgentParser::symbol_type
- AgentParser::make_USER_CONTEXT (const location_type& l)
+ AgentParser::make_USER_CONTEXT (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_USER_CONTEXT, l);
+ return symbol_type (token::TOKEN_USER_CONTEXT, YY_MOVE (l));
}
+ inline
AgentParser::symbol_type
- AgentParser::make_COMMENT (const location_type& l)
+ AgentParser::make_COMMENT (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_COMMENT, l);
+ return symbol_type (token::TOKEN_COMMENT, YY_MOVE (l));
}
+ inline
AgentParser::symbol_type
- AgentParser::make_CONTROL_SOCKETS (const location_type& l)
+ AgentParser::make_CONTROL_SOCKETS (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_CONTROL_SOCKETS, l);
+ return symbol_type (token::TOKEN_CONTROL_SOCKETS, YY_MOVE (l));
}
+ inline
AgentParser::symbol_type
- AgentParser::make_DHCP4_SERVER (const location_type& l)
+ AgentParser::make_DHCP4_SERVER (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_DHCP4_SERVER, l);
+ return symbol_type (token::TOKEN_DHCP4_SERVER, YY_MOVE (l));
}
+ inline
AgentParser::symbol_type
- AgentParser::make_DHCP6_SERVER (const location_type& l)
+ AgentParser::make_DHCP6_SERVER (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_DHCP6_SERVER, l);
+ return symbol_type (token::TOKEN_DHCP6_SERVER, YY_MOVE (l));
}
+ inline
AgentParser::symbol_type
- AgentParser::make_D2_SERVER (const location_type& l)
+ AgentParser::make_D2_SERVER (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_D2_SERVER, l);
+ return symbol_type (token::TOKEN_D2_SERVER, YY_MOVE (l));
}
+ inline
AgentParser::symbol_type
- AgentParser::make_SOCKET_NAME (const location_type& l)
+ AgentParser::make_SOCKET_NAME (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_SOCKET_NAME, l);
+ return symbol_type (token::TOKEN_SOCKET_NAME, YY_MOVE (l));
}
+ inline
AgentParser::symbol_type
- AgentParser::make_SOCKET_TYPE (const location_type& l)
+ AgentParser::make_SOCKET_TYPE (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_SOCKET_TYPE, l);
+ return symbol_type (token::TOKEN_SOCKET_TYPE, YY_MOVE (l));
}
+ inline
AgentParser::symbol_type
- AgentParser::make_UNIX (const location_type& l)
+ AgentParser::make_UNIX (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_UNIX, l);
+ return symbol_type (token::TOKEN_UNIX, YY_MOVE (l));
}
+ inline
AgentParser::symbol_type
- AgentParser::make_HOOKS_LIBRARIES (const location_type& l)
+ AgentParser::make_HOOKS_LIBRARIES (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_HOOKS_LIBRARIES, l);
+ return symbol_type (token::TOKEN_HOOKS_LIBRARIES, YY_MOVE (l));
}
+ inline
AgentParser::symbol_type
- AgentParser::make_LIBRARY (const location_type& l)
+ AgentParser::make_LIBRARY (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_LIBRARY, l);
+ return symbol_type (token::TOKEN_LIBRARY, YY_MOVE (l));
}
+ inline
AgentParser::symbol_type
- AgentParser::make_PARAMETERS (const location_type& l)
+ AgentParser::make_PARAMETERS (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_PARAMETERS, l);
+ return symbol_type (token::TOKEN_PARAMETERS, YY_MOVE (l));
}
+ inline
AgentParser::symbol_type
- AgentParser::make_LOGGING (const location_type& l)
+ AgentParser::make_LOGGING (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_LOGGING, l);
+ return symbol_type (token::TOKEN_LOGGING, YY_MOVE (l));
}
+ inline
AgentParser::symbol_type
- AgentParser::make_LOGGERS (const location_type& l)
+ AgentParser::make_LOGGERS (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_LOGGERS, l);
+ return symbol_type (token::TOKEN_LOGGERS, YY_MOVE (l));
}
+ inline
AgentParser::symbol_type
- AgentParser::make_NAME (const location_type& l)
+ AgentParser::make_NAME (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_NAME, l);
+ return symbol_type (token::TOKEN_NAME, YY_MOVE (l));
}
+ inline
AgentParser::symbol_type
- AgentParser::make_OUTPUT_OPTIONS (const location_type& l)
+ AgentParser::make_OUTPUT_OPTIONS (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_OUTPUT_OPTIONS, l);
+ return symbol_type (token::TOKEN_OUTPUT_OPTIONS, YY_MOVE (l));
}
+ inline
AgentParser::symbol_type
- AgentParser::make_OUTPUT (const location_type& l)
+ AgentParser::make_OUTPUT (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_OUTPUT, l);
+ return symbol_type (token::TOKEN_OUTPUT, YY_MOVE (l));
}
+ inline
AgentParser::symbol_type
- AgentParser::make_DEBUGLEVEL (const location_type& l)
+ AgentParser::make_DEBUGLEVEL (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_DEBUGLEVEL, l);
+ return symbol_type (token::TOKEN_DEBUGLEVEL, YY_MOVE (l));
}
+ inline
AgentParser::symbol_type
- AgentParser::make_SEVERITY (const location_type& l)
+ AgentParser::make_SEVERITY (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_SEVERITY, l);
+ return symbol_type (token::TOKEN_SEVERITY, YY_MOVE (l));
}
+ inline
AgentParser::symbol_type
- AgentParser::make_FLUSH (const location_type& l)
+ AgentParser::make_FLUSH (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_FLUSH, l);
+ return symbol_type (token::TOKEN_FLUSH, YY_MOVE (l));
}
+ inline
AgentParser::symbol_type
- AgentParser::make_MAXSIZE (const location_type& l)
+ AgentParser::make_MAXSIZE (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_MAXSIZE, l);
+ return symbol_type (token::TOKEN_MAXSIZE, YY_MOVE (l));
}
+ inline
AgentParser::symbol_type
- AgentParser::make_MAXVER (const location_type& l)
+ AgentParser::make_MAXVER (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_MAXVER, l);
+ return symbol_type (token::TOKEN_MAXVER, YY_MOVE (l));
}
+ inline
AgentParser::symbol_type
- AgentParser::make_DHCP4 (const location_type& l)
+ AgentParser::make_DHCP4 (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_DHCP4, l);
+ return symbol_type (token::TOKEN_DHCP4, YY_MOVE (l));
}
+ inline
AgentParser::symbol_type
- AgentParser::make_DHCP6 (const location_type& l)
+ AgentParser::make_DHCP6 (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_DHCP6, l);
+ return symbol_type (token::TOKEN_DHCP6, YY_MOVE (l));
}
+ inline
AgentParser::symbol_type
- AgentParser::make_DHCPDDNS (const location_type& l)
+ AgentParser::make_DHCPDDNS (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_DHCPDDNS, l);
+ return symbol_type (token::TOKEN_DHCPDDNS, YY_MOVE (l));
}
+ inline
AgentParser::symbol_type
- AgentParser::make_START_JSON (const location_type& l)
+ AgentParser::make_START_JSON (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_START_JSON, l);
+ return symbol_type (token::TOKEN_START_JSON, YY_MOVE (l));
}
+ inline
AgentParser::symbol_type
- AgentParser::make_START_AGENT (const location_type& l)
+ AgentParser::make_START_AGENT (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_START_AGENT, l);
+ return symbol_type (token::TOKEN_START_AGENT, YY_MOVE (l));
}
+ inline
AgentParser::symbol_type
- AgentParser::make_START_SUB_AGENT (const location_type& l)
+ AgentParser::make_START_SUB_AGENT (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_START_SUB_AGENT, l);
+ return symbol_type (token::TOKEN_START_SUB_AGENT, YY_MOVE (l));
}
+ inline
AgentParser::symbol_type
- AgentParser::make_STRING (const std::string& v, const location_type& l)
+ AgentParser::make_STRING (YY_COPY (std::string) v, YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_STRING, v, l);
+ return symbol_type (token::TOKEN_STRING, YY_MOVE (v), YY_MOVE (l));
}
+ inline
AgentParser::symbol_type
- AgentParser::make_INTEGER (const int64_t& v, const location_type& l)
+ AgentParser::make_INTEGER (YY_COPY (int64_t) v, YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_INTEGER, v, l);
+ return symbol_type (token::TOKEN_INTEGER, YY_MOVE (v), YY_MOVE (l));
}
+ inline
AgentParser::symbol_type
- AgentParser::make_FLOAT (const double& v, const location_type& l)
+ AgentParser::make_FLOAT (YY_COPY (double) v, YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_FLOAT, v, l);
+ return symbol_type (token::TOKEN_FLOAT, YY_MOVE (v), YY_MOVE (l));
}
+ inline
AgentParser::symbol_type
- AgentParser::make_BOOLEAN (const bool& v, const location_type& l)
+ AgentParser::make_BOOLEAN (YY_COPY (bool) v, YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_BOOLEAN, v, l);
+ return symbol_type (token::TOKEN_BOOLEAN, YY_MOVE (v), YY_MOVE (l));
}
-#line 14 "agent_parser.yy" // lalr1.cc:379
+#line 14 "agent_parser.yy" // lalr1.cc:404
} } // isc::agent
-#line 1488 "agent_parser.h" // lalr1.cc:379
+#line 1686 "agent_parser.h" // lalr1.cc:404
-// Generated 201811151407
-// A Bison parser, made by GNU Bison 3.0.5.
+// Generated 201811172153
+// A Bison parser, made by GNU Bison 3.2.1.
// Locations for Bison parsers in C++
#ifndef YY_AGENT_LOCATION_HH_INCLUDED
# define YY_AGENT_LOCATION_HH_INCLUDED
-# include "position.hh"
+# include <algorithm> // std::max
+# include <iostream>
+# include <string>
-#line 14 "agent_parser.yy" // location.cc:292
+# ifndef YY_NULLPTR
+# if defined __cplusplus
+# if 201103L <= __cplusplus
+# define YY_NULLPTR nullptr
+# else
+# define YY_NULLPTR 0
+# endif
+# else
+# define YY_NULLPTR ((void*)0)
+# endif
+# endif
+
+#line 14 "agent_parser.yy" // location.cc:339
namespace isc { namespace agent {
-#line 46 "location.hh" // location.cc:292
- /// Abstract a location.
+#line 60 "location.hh" // location.cc:339
+ /// A point in a source file.
+ class position
+ {
+ public:
+ /// Construct a position.
+ explicit position (std::string* f = YY_NULLPTR,
+ unsigned l = 1u,
+ unsigned c = 1u)
+ : filename (f)
+ , line (l)
+ , column (c)
+ {}
+
+
+ /// Initialization.
+ void initialize (std::string* fn = YY_NULLPTR,
+ unsigned l = 1u,
+ unsigned c = 1u)
+ {
+ filename = fn;
+ line = l;
+ column = c;
+ }
+
+ /** \name Line and Column related manipulators
+ ** \{ */
+ /// (line related) Advance to the COUNT next lines.
+ void lines (int count = 1)
+ {
+ if (count)
+ {
+ column = 1u;
+ line = add_ (line, count, 1);
+ }
+ }
+
+ /// (column related) Advance to the COUNT next columns.
+ void columns (int count = 1)
+ {
+ column = add_ (column, count, 1);
+ }
+ /** \} */
+
+ /// File name to which this position refers.
+ std::string* filename;
+ /// Current line number.
+ unsigned line;
+ /// Current column number.
+ unsigned column;
+
+ private:
+ /// Compute max (min, lhs+rhs).
+ static unsigned add_ (unsigned lhs, int rhs, int min)
+ {
+ return static_cast<unsigned> (std::max (min,
+ static_cast<int> (lhs) + rhs));
+ }
+ };
+
+ /// Add \a width columns, in place.
+ inline position&
+ operator+= (position& res, int width)
+ {
+ res.columns (width);
+ return res;
+ }
+
+ /// Add \a width columns.
+ inline position
+ operator+ (position res, int width)
+ {
+ return res += width;
+ }
+
+ /// Subtract \a width columns, in place.
+ inline position&
+ operator-= (position& res, int width)
+ {
+ return res += -width;
+ }
+
+ /// Subtract \a width columns.
+ inline position
+ operator- (position res, int width)
+ {
+ return res -= width;
+ }
+
+ /// Compare two position objects.
+ inline bool
+ operator== (const position& pos1, const position& pos2)
+ {
+ return (pos1.line == pos2.line
+ && pos1.column == pos2.column
+ && (pos1.filename == pos2.filename
+ || (pos1.filename && pos2.filename
+ && *pos1.filename == *pos2.filename)));
+ }
+
+ /// Compare two position objects.
+ inline bool
+ operator!= (const position& pos1, const position& pos2)
+ {
+ return !(pos1 == pos2);
+ }
+
+ /** \brief Intercept output stream redirection.
+ ** \param ostr the destination output stream
+ ** \param pos a reference to the position to redirect
+ */
+ template <typename YYChar>
+ std::basic_ostream<YYChar>&
+ operator<< (std::basic_ostream<YYChar>& ostr, const position& pos)
+ {
+ if (pos.filename)
+ ostr << *pos.filename << ':';
+ return ostr << pos.line << '.' << pos.column;
+ }
+
+ /// Two points in a source file.
class location
{
public:
** Avoid duplicate information.
*/
template <typename YYChar>
- inline std::basic_ostream<YYChar>&
+ std::basic_ostream<YYChar>&
operator<< (std::basic_ostream<YYChar>& ostr, const location& loc)
{
unsigned end_col = 0 < loc.end.column ? loc.end.column - 1 : 0;
return ostr;
}
-#line 14 "agent_parser.yy" // location.cc:292
+#line 14 "agent_parser.yy" // location.cc:339
} } // isc::agent
-#line 189 "location.hh" // location.cc:292
+#line 322 "location.hh" // location.cc:339
#endif // !YY_AGENT_LOCATION_HH_INCLUDED
-// Generated 201811151407
-// A Bison parser, made by GNU Bison 3.0.5.
-
-// Positions for Bison parsers in C++
-
-// Copyright (C) 2002-2015, 2018 Free Software Foundation, Inc.
-
-// This program is free software: you can redistribute it and/or modify
-// it under the terms of the GNU General Public License as published by
-// the Free Software Foundation, either version 3 of the License, or
-// (at your option) any later version.
-
-// This program is distributed in the hope that it will be useful,
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-// GNU General Public License for more details.
-
-// You should have received a copy of the GNU General Public License
-// along with this program. If not, see <http://www.gnu.org/licenses/>.
-
-// As a special exception, you may create a larger work that contains
-// part or all of the Bison parser skeleton and distribute that work
-// under terms of your choice, so long as that work isn't itself a
-// parser generator using the skeleton or a modified version thereof
-// as a parser skeleton. Alternatively, if you modify or redistribute
-// the parser skeleton itself, you may (at your option) remove this
-// special exception, which will cause the skeleton and the resulting
-// Bison output files to be licensed under the GNU General Public
-// License without this special exception.
-
-// This special exception was added by the Free Software Foundation in
-// version 2.2 of Bison.
-
-/**
- ** \file position.hh
- ** Define the isc::agent::position class.
- */
-
-#ifndef YY_AGENT_POSITION_HH_INCLUDED
-# define YY_AGENT_POSITION_HH_INCLUDED
-
-# include <algorithm> // std::max
-# include <iostream>
-# include <string>
-
-# ifndef YY_NULLPTR
-# if defined __cplusplus && 201103L <= __cplusplus
-# define YY_NULLPTR nullptr
-# else
-# define YY_NULLPTR 0
-# endif
-# endif
-
-#line 14 "agent_parser.yy" // location.cc:292
-namespace isc { namespace agent {
-#line 56 "position.hh" // location.cc:292
- /// Abstract a position.
- class position
- {
- public:
- /// Construct a position.
- explicit position (std::string* f = YY_NULLPTR,
- unsigned l = 1u,
- unsigned c = 1u)
- : filename (f)
- , line (l)
- , column (c)
- {}
-
-
- /// Initialization.
- void initialize (std::string* fn = YY_NULLPTR,
- unsigned l = 1u,
- unsigned c = 1u)
- {
- filename = fn;
- line = l;
- column = c;
- }
-
- /** \name Line and Column related manipulators
- ** \{ */
- /// (line related) Advance to the COUNT next lines.
- void lines (int count = 1)
- {
- if (count)
- {
- column = 1u;
- line = add_ (line, count, 1);
- }
- }
-
- /// (column related) Advance to the COUNT next columns.
- void columns (int count = 1)
- {
- column = add_ (column, count, 1);
- }
- /** \} */
-
- /// File name to which this position refers.
- std::string* filename;
- /// Current line number.
- unsigned line;
- /// Current column number.
- unsigned column;
-
- private:
- /// Compute max(min, lhs+rhs) (provided min <= lhs).
- static unsigned add_ (unsigned lhs, int rhs, unsigned min)
- {
- return (0 < rhs || -static_cast<unsigned>(rhs) < lhs
- ? rhs + lhs
- : min);
- }
- };
-
- /// Add \a width columns, in place.
- inline position&
- operator+= (position& res, int width)
- {
- res.columns (width);
- return res;
- }
-
- /// Add \a width columns.
- inline position
- operator+ (position res, int width)
- {
- return res += width;
- }
-
- /// Subtract \a width columns, in place.
- inline position&
- operator-= (position& res, int width)
- {
- return res += -width;
- }
-
- /// Subtract \a width columns.
- inline position
- operator- (position res, int width)
- {
- return res -= width;
- }
-
- /// Compare two position objects.
- inline bool
- operator== (const position& pos1, const position& pos2)
- {
- return (pos1.line == pos2.line
- && pos1.column == pos2.column
- && (pos1.filename == pos2.filename
- || (pos1.filename && pos2.filename
- && *pos1.filename == *pos2.filename)));
- }
-
- /// Compare two position objects.
- inline bool
- operator!= (const position& pos1, const position& pos2)
- {
- return !(pos1 == pos2);
- }
-
- /** \brief Intercept output stream redirection.
- ** \param ostr the destination output stream
- ** \param pos a reference to the position to redirect
- */
- template <typename YYChar>
- inline std::basic_ostream<YYChar>&
- operator<< (std::basic_ostream<YYChar>& ostr, const position& pos)
- {
- if (pos.filename)
- ostr << *pos.filename << ':';
- return ostr << pos.line << '.' << pos.column;
- }
-
-#line 14 "agent_parser.yy" // location.cc:292
-} } // isc::agent
-#line 179 "position.hh" // location.cc:292
-#endif // !YY_AGENT_POSITION_HH_INCLUDED
+// Generated 201811172153
+// A Bison parser, made by GNU Bison 3.2.1.
+
+// Starting with Bison 3.2, this file is useless: the structure it
+// used to define is now defined in "location.hh".
+//
+// To get rid of this file:
+// 1. add 'require "3.2"' (or newer) to your grammar file
+// 2. remove references to this file from your build system
+// 3. if you used to include it, include "location.hh" instead.
+
+#include "location.hh"
-// Generated 201811151407
-// A Bison parser, made by GNU Bison 3.0.5.
-
-// Stack handling for Bison parsers in C++
-
-// Copyright (C) 2002-2015, 2018 Free Software Foundation, Inc.
-
-// This program is free software: you can redistribute it and/or modify
-// it under the terms of the GNU General Public License as published by
-// the Free Software Foundation, either version 3 of the License, or
-// (at your option) any later version.
-
-// This program is distributed in the hope that it will be useful,
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-// GNU General Public License for more details.
-
-// You should have received a copy of the GNU General Public License
-// along with this program. If not, see <http://www.gnu.org/licenses/>.
-
-// As a special exception, you may create a larger work that contains
-// part or all of the Bison parser skeleton and distribute that work
-// under terms of your choice, so long as that work isn't itself a
-// parser generator using the skeleton or a modified version thereof
-// as a parser skeleton. Alternatively, if you modify or redistribute
-// the parser skeleton itself, you may (at your option) remove this
-// special exception, which will cause the skeleton and the resulting
-// Bison output files to be licensed under the GNU General Public
-// License without this special exception.
-
-// This special exception was added by the Free Software Foundation in
-// version 2.2 of Bison.
-
-/**
- ** \file stack.hh
- ** Define the isc::agent::stack class.
- */
-
-#ifndef YY_AGENT_STACK_HH_INCLUDED
-# define YY_AGENT_STACK_HH_INCLUDED
-
-# include <vector>
-
-#line 14 "agent_parser.yy" // stack.hh:131
-namespace isc { namespace agent {
-#line 46 "stack.hh" // stack.hh:131
- /// A stack with random access from its top.
- template <class T, class S = std::vector<T> >
- class stack
- {
- public:
- // Hide our reversed order.
- typedef typename S::reverse_iterator iterator;
- typedef typename S::const_reverse_iterator const_iterator;
-
- stack ()
- : seq_ ()
- {
- seq_.reserve (200);
- }
-
- stack (unsigned n)
- : seq_ (n)
- {}
-
- /// Random access.
- ///
- /// Index 0 returns the topmost element.
- T&
- operator[] (unsigned i)
- {
- return seq_[seq_.size () - 1 - i];
- }
-
- /// Random access.
- ///
- /// Index 0 returns the topmost element.
- const T&
- operator[] (unsigned i) const
- {
- return seq_[seq_.size () - 1 - i];
- }
-
- /// Steal the contents of \a t.
- ///
- /// Close to move-semantics.
- void
- push (T& t)
- {
- seq_.push_back (T());
- operator[](0).move (t);
- }
-
- void
- pop (unsigned n = 1)
- {
- for (; n; --n)
- seq_.pop_back ();
- }
-
- void
- clear ()
- {
- seq_.clear ();
- }
-
- typename S::size_type
- size () const
- {
- return seq_.size ();
- }
-
- const_iterator
- begin () const
- {
- return seq_.rbegin ();
- }
-
- const_iterator
- end () const
- {
- return seq_.rend ();
- }
-
- private:
- stack (const stack&);
- stack& operator= (const stack&);
- /// The wrapped container.
- S seq_;
- };
-
- /// Present a slice of the top of a stack.
- template <class T, class S = stack<T> >
- class slice
- {
- public:
- slice (const S& stack, unsigned range)
- : stack_ (stack)
- , range_ (range)
- {}
-
- const T&
- operator [] (unsigned i) const
- {
- return stack_[range_ - i];
- }
-
- private:
- const S& stack_;
- unsigned range_;
- };
-
-#line 14 "agent_parser.yy" // stack.hh:131
-} } // isc::agent
-#line 155 "stack.hh" // stack.hh:131
-
-#endif // !YY_AGENT_STACK_HH_INCLUDED
+// Generated 201811172153
+// A Bison parser, made by GNU Bison 3.2.1.
+
+// Starting with Bison 3.2, this file is useless: the structure it
+// used to define is now defined with the parser itself.
+//
+// To get rid of this file:
+// 1. add 'require "3.2"' (or newer) to your grammar file
+// 2. remove references to this file from your build system.
-// A Bison parser, made by GNU Bison 3.0.5.
+// A Bison parser, made by GNU Bison 3.2.1.
// Skeleton implementation for Bison LALR(1) parsers in C++
// This special exception was added by the Free Software Foundation in
// version 2.2 of Bison.
+// Undocumented macros, especially those whose name start with YY_,
+// are private implementation details. Do not rely on them.
+
+
// Take the name prefix into account.
#define yylex d2_parser_lex
-// First part of user declarations.
-#line 39 "d2_parser.cc" // lalr1.cc:406
-
-# ifndef YY_NULLPTR
-# if defined __cplusplus && 201103L <= __cplusplus
-# define YY_NULLPTR nullptr
-# else
-# define YY_NULLPTR 0
-# endif
-# endif
#include "d2_parser.h"
-// User implementation prologue.
-#line 53 "d2_parser.cc" // lalr1.cc:414
// Unqualified %code blocks.
-#line 34 "d2_parser.yy" // lalr1.cc:415
+#line 34 "d2_parser.yy" // lalr1.cc:438
#include <d2/parser_context.h>
-#line 59 "d2_parser.cc" // lalr1.cc:415
+#line 51 "d2_parser.cc" // lalr1.cc:438
#ifndef YY_
# endif
#endif
+// Whether we are compiled with exception support.
+#ifndef YY_EXCEPTIONS
+# if defined __GNUC__ && !defined __EXCEPTIONS
+# define YY_EXCEPTIONS 0
+# else
+# define YY_EXCEPTIONS 1
+# endif
+#endif
+
#define YYRHSLOC(Rhs, K) ((Rhs)[K].location)
/* YYLLOC_DEFAULT -- Set CURRENT to span from RHS[1] to RHS[N].
If N is 0, then set CURRENT to the empty location which ends
#define YYERROR goto yyerrorlab
#define YYRECOVERING() (!!yyerrstatus_)
-#line 14 "d2_parser.yy" // lalr1.cc:481
+#line 14 "d2_parser.yy" // lalr1.cc:513
namespace isc { namespace d2 {
-#line 145 "d2_parser.cc" // lalr1.cc:481
+#line 146 "d2_parser.cc" // lalr1.cc:513
/* Return YYSTR after stripping away unnecessary quotes and
backslashes, so that it's suitable for yyerror. The heuristic is
D2Parser::stack_symbol_type::stack_symbol_type ()
{}
- D2Parser::stack_symbol_type::stack_symbol_type (const stack_symbol_type& that)
- : super_type (that.state, that.location)
+ D2Parser::stack_symbol_type::stack_symbol_type (YY_RVREF (stack_symbol_type) that)
+ : super_type (YY_MOVE (that.state), YY_MOVE (that.location))
{
switch (that.type_get ())
{
case 68: // value
case 72: // map_value
case 96: // ncr_protocol_value
- value.copy< ElementPtr > (that.value);
+ value.YY_MOVE_OR_COPY< ElementPtr > (YY_MOVE (that.value));
break;
case 56: // "boolean"
- value.copy< bool > (that.value);
+ value.YY_MOVE_OR_COPY< bool > (YY_MOVE (that.value));
break;
case 55: // "floating point"
- value.copy< double > (that.value);
+ value.YY_MOVE_OR_COPY< double > (YY_MOVE (that.value));
break;
case 54: // "integer"
- value.copy< int64_t > (that.value);
+ value.YY_MOVE_OR_COPY< int64_t > (YY_MOVE (that.value));
break;
case 53: // "constant string"
- value.copy< std::string > (that.value);
+ value.YY_MOVE_OR_COPY< std::string > (YY_MOVE (that.value));
break;
default:
break;
}
+#if defined __cplusplus && 201103L <= __cplusplus
+ // that is emptied.
+ that.state = empty_state;
+#endif
}
- D2Parser::stack_symbol_type::stack_symbol_type (state_type s, symbol_type& that)
- : super_type (s, that.location)
+ D2Parser::stack_symbol_type::stack_symbol_type (state_type s, YY_MOVE_REF (symbol_type) that)
+ : super_type (s, YY_MOVE (that.location))
{
switch (that.type_get ())
{
case 68: // value
case 72: // map_value
case 96: // ncr_protocol_value
- value.move< ElementPtr > (that.value);
+ value.move< ElementPtr > (YY_MOVE (that.value));
break;
case 56: // "boolean"
- value.move< bool > (that.value);
+ value.move< bool > (YY_MOVE (that.value));
break;
case 55: // "floating point"
- value.move< double > (that.value);
+ value.move< double > (YY_MOVE (that.value));
break;
case 54: // "integer"
- value.move< int64_t > (that.value);
+ value.move< int64_t > (YY_MOVE (that.value));
break;
case 53: // "constant string"
- value.move< std::string > (that.value);
+ value.move< std::string > (YY_MOVE (that.value));
break;
default:
that.type = empty_symbol;
}
+#if !defined __cplusplus || __cplusplus < 201103L
D2Parser::stack_symbol_type&
- D2Parser::stack_symbol_type::operator= (const stack_symbol_type& that)
+ D2Parser::stack_symbol_type::operator= (stack_symbol_type& that)
{
state = that.state;
switch (that.type_get ())
case 68: // value
case 72: // map_value
case 96: // ncr_protocol_value
- value.copy< ElementPtr > (that.value);
+ value.move< ElementPtr > (that.value);
break;
case 56: // "boolean"
- value.copy< bool > (that.value);
+ value.move< bool > (that.value);
break;
case 55: // "floating point"
- value.copy< double > (that.value);
+ value.move< double > (that.value);
break;
case 54: // "integer"
- value.copy< int64_t > (that.value);
+ value.move< int64_t > (that.value);
break;
case 53: // "constant string"
- value.copy< std::string > (that.value);
+ value.move< std::string > (that.value);
break;
default:
}
location = that.location;
+ // that is emptied.
+ that.state = empty_state;
return *this;
}
-
+#endif
template <typename Base>
void
{
case 53: // "constant string"
-#line 111 "d2_parser.yy" // lalr1.cc:635
+#line 111 "d2_parser.yy" // lalr1.cc:672
{ yyoutput << yysym.value.template as< std::string > (); }
-#line 378 "d2_parser.cc" // lalr1.cc:635
+#line 386 "d2_parser.cc" // lalr1.cc:672
break;
case 54: // "integer"
-#line 111 "d2_parser.yy" // lalr1.cc:635
+#line 111 "d2_parser.yy" // lalr1.cc:672
{ yyoutput << yysym.value.template as< int64_t > (); }
-#line 385 "d2_parser.cc" // lalr1.cc:635
+#line 393 "d2_parser.cc" // lalr1.cc:672
break;
case 55: // "floating point"
-#line 111 "d2_parser.yy" // lalr1.cc:635
+#line 111 "d2_parser.yy" // lalr1.cc:672
{ yyoutput << yysym.value.template as< double > (); }
-#line 392 "d2_parser.cc" // lalr1.cc:635
+#line 400 "d2_parser.cc" // lalr1.cc:672
break;
case 56: // "boolean"
-#line 111 "d2_parser.yy" // lalr1.cc:635
+#line 111 "d2_parser.yy" // lalr1.cc:672
{ yyoutput << yysym.value.template as< bool > (); }
-#line 399 "d2_parser.cc" // lalr1.cc:635
+#line 407 "d2_parser.cc" // lalr1.cc:672
break;
case 68: // value
-#line 111 "d2_parser.yy" // lalr1.cc:635
+#line 111 "d2_parser.yy" // lalr1.cc:672
{ yyoutput << yysym.value.template as< ElementPtr > (); }
-#line 406 "d2_parser.cc" // lalr1.cc:635
+#line 414 "d2_parser.cc" // lalr1.cc:672
break;
case 72: // map_value
-#line 111 "d2_parser.yy" // lalr1.cc:635
+#line 111 "d2_parser.yy" // lalr1.cc:672
{ yyoutput << yysym.value.template as< ElementPtr > (); }
-#line 413 "d2_parser.cc" // lalr1.cc:635
+#line 421 "d2_parser.cc" // lalr1.cc:672
break;
case 96: // ncr_protocol_value
-#line 111 "d2_parser.yy" // lalr1.cc:635
+#line 111 "d2_parser.yy" // lalr1.cc:672
{ yyoutput << yysym.value.template as< ElementPtr > (); }
-#line 420 "d2_parser.cc" // lalr1.cc:635
+#line 428 "d2_parser.cc" // lalr1.cc:672
break;
#endif
void
- D2Parser::yypush_ (const char* m, state_type s, symbol_type& sym)
+ D2Parser::yypush_ (const char* m, YY_MOVE_REF (stack_symbol_type) sym)
{
- stack_symbol_type t (s, sym);
- yypush_ (m, t);
+ if (m)
+ YY_SYMBOL_PRINT (m, sym);
+ yystack_.push (YY_MOVE (sym));
}
void
- D2Parser::yypush_ (const char* m, stack_symbol_type& s)
+ D2Parser::yypush_ (const char* m, state_type s, YY_MOVE_REF (symbol_type) sym)
{
- if (m)
- YY_SYMBOL_PRINT (m, s);
- yystack_.push (s);
+#if defined __cplusplus && 201103L <= __cplusplus
+ yypush_ (m, stack_symbol_type (s, std::move (sym)));
+#else
+ stack_symbol_type ss (s, sym);
+ yypush_ (m, ss);
+#endif
}
void
- D2Parser::yypop_ (unsigned n)
+ D2Parser::yypop_ (int n)
{
yystack_.pop (n);
}
return yyvalue == yytable_ninf_;
}
+ int
+ D2Parser::operator() ()
+ {
+ return parse ();
+ }
+
int
D2Parser::parse ()
{
/// The return value of parse ().
int yyresult;
- // FIXME: This shoud be completely indented. It is not yet to
- // avoid gratuitous conflicts when merging into the master branch.
+#if YY_EXCEPTIONS
try
+#endif // YY_EXCEPTIONS
{
YYCDEBUG << "Starting parse\n";
location values to have been already stored, initialize these
stacks with a primary value. */
yystack_.clear ();
- yypush_ (YY_NULLPTR, 0, yyla);
+ yypush_ (YY_NULLPTR, 0, YY_MOVE (yyla));
// A new symbol was pushed on the stack.
yynewstate:
// Backup.
yybackup:
-
// Try to take a decision without lookahead.
yyn = yypact_[yystack_[0].state];
if (yy_pact_value_is_default_ (yyn))
if (yyla.empty ())
{
YYCDEBUG << "Reading a token: ";
+#if YY_EXCEPTIONS
try
+#endif // YY_EXCEPTIONS
{
symbol_type yylookahead (yylex (ctx));
yyla.move (yylookahead);
}
+#if YY_EXCEPTIONS
catch (const syntax_error& yyexc)
{
error (yyexc);
goto yyerrlab1;
}
+#endif // YY_EXCEPTIONS
}
YY_SYMBOL_PRINT ("Next token is", yyla);
--yyerrstatus_;
// Shift the lookahead token.
- yypush_ ("Shifting", yyn, yyla);
+ yypush_ ("Shifting", yyn, YY_MOVE (yyla));
goto yynewstate;
/*-----------------------------------------------------------.
case 68: // value
case 72: // map_value
case 96: // ncr_protocol_value
- yylhs.value.build< ElementPtr > ();
+ yylhs.value.emplace< ElementPtr > ();
break;
case 56: // "boolean"
- yylhs.value.build< bool > ();
+ yylhs.value.emplace< bool > ();
break;
case 55: // "floating point"
- yylhs.value.build< double > ();
+ yylhs.value.emplace< double > ();
break;
case 54: // "integer"
- yylhs.value.build< int64_t > ();
+ yylhs.value.emplace< int64_t > ();
break;
case 53: // "constant string"
- yylhs.value.build< std::string > ();
+ yylhs.value.emplace< std::string > ();
break;
default:
// Perform the reduction.
YY_REDUCE_PRINT (yyn);
+#if YY_EXCEPTIONS
try
+#endif // YY_EXCEPTIONS
{
switch (yyn)
{
case 2:
-#line 120 "d2_parser.yy" // lalr1.cc:856
+#line 120 "d2_parser.yy" // lalr1.cc:907
{ ctx.ctx_ = ctx.NO_KEYWORD; }
-#line 660 "d2_parser.cc" // lalr1.cc:856
+#line 683 "d2_parser.cc" // lalr1.cc:907
break;
case 4:
-#line 121 "d2_parser.yy" // lalr1.cc:856
+#line 121 "d2_parser.yy" // lalr1.cc:907
{ ctx.ctx_ = ctx.CONFIG; }
-#line 666 "d2_parser.cc" // lalr1.cc:856
+#line 689 "d2_parser.cc" // lalr1.cc:907
break;
case 6:
-#line 122 "d2_parser.yy" // lalr1.cc:856
+#line 122 "d2_parser.yy" // lalr1.cc:907
{ ctx.ctx_ = ctx.DHCPDDNS; }
-#line 672 "d2_parser.cc" // lalr1.cc:856
+#line 695 "d2_parser.cc" // lalr1.cc:907
break;
case 8:
-#line 123 "d2_parser.yy" // lalr1.cc:856
+#line 123 "d2_parser.yy" // lalr1.cc:907
{ ctx.ctx_ = ctx.TSIG_KEY; }
-#line 678 "d2_parser.cc" // lalr1.cc:856
+#line 701 "d2_parser.cc" // lalr1.cc:907
break;
case 10:
-#line 124 "d2_parser.yy" // lalr1.cc:856
+#line 124 "d2_parser.yy" // lalr1.cc:907
{ ctx.ctx_ = ctx.TSIG_KEYS; }
-#line 684 "d2_parser.cc" // lalr1.cc:856
+#line 707 "d2_parser.cc" // lalr1.cc:907
break;
case 12:
-#line 125 "d2_parser.yy" // lalr1.cc:856
+#line 125 "d2_parser.yy" // lalr1.cc:907
{ ctx.ctx_ = ctx.DDNS_DOMAIN; }
-#line 690 "d2_parser.cc" // lalr1.cc:856
+#line 713 "d2_parser.cc" // lalr1.cc:907
break;
case 14:
-#line 126 "d2_parser.yy" // lalr1.cc:856
+#line 126 "d2_parser.yy" // lalr1.cc:907
{ ctx.ctx_ = ctx.DDNS_DOMAINS; }
-#line 696 "d2_parser.cc" // lalr1.cc:856
+#line 719 "d2_parser.cc" // lalr1.cc:907
break;
case 16:
-#line 127 "d2_parser.yy" // lalr1.cc:856
+#line 127 "d2_parser.yy" // lalr1.cc:907
{ ctx.ctx_ = ctx.DNS_SERVERS; }
-#line 702 "d2_parser.cc" // lalr1.cc:856
+#line 725 "d2_parser.cc" // lalr1.cc:907
break;
case 18:
-#line 128 "d2_parser.yy" // lalr1.cc:856
+#line 128 "d2_parser.yy" // lalr1.cc:907
{ ctx.ctx_ = ctx.DNS_SERVERS; }
-#line 708 "d2_parser.cc" // lalr1.cc:856
+#line 731 "d2_parser.cc" // lalr1.cc:907
break;
case 20:
-#line 136 "d2_parser.yy" // lalr1.cc:856
+#line 136 "d2_parser.yy" // lalr1.cc:907
{ yylhs.value.as< ElementPtr > () = ElementPtr(new IntElement(yystack_[0].value.as< int64_t > (), ctx.loc2pos(yystack_[0].location))); }
-#line 714 "d2_parser.cc" // lalr1.cc:856
+#line 737 "d2_parser.cc" // lalr1.cc:907
break;
case 21:
-#line 137 "d2_parser.yy" // lalr1.cc:856
+#line 137 "d2_parser.yy" // lalr1.cc:907
{ yylhs.value.as< ElementPtr > () = ElementPtr(new DoubleElement(yystack_[0].value.as< double > (), ctx.loc2pos(yystack_[0].location))); }
-#line 720 "d2_parser.cc" // lalr1.cc:856
+#line 743 "d2_parser.cc" // lalr1.cc:907
break;
case 22:
-#line 138 "d2_parser.yy" // lalr1.cc:856
+#line 138 "d2_parser.yy" // lalr1.cc:907
{ yylhs.value.as< ElementPtr > () = ElementPtr(new BoolElement(yystack_[0].value.as< bool > (), ctx.loc2pos(yystack_[0].location))); }
-#line 726 "d2_parser.cc" // lalr1.cc:856
+#line 749 "d2_parser.cc" // lalr1.cc:907
break;
case 23:
-#line 139 "d2_parser.yy" // lalr1.cc:856
+#line 139 "d2_parser.yy" // lalr1.cc:907
{ yylhs.value.as< ElementPtr > () = ElementPtr(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location))); }
-#line 732 "d2_parser.cc" // lalr1.cc:856
+#line 755 "d2_parser.cc" // lalr1.cc:907
break;
case 24:
-#line 140 "d2_parser.yy" // lalr1.cc:856
+#line 140 "d2_parser.yy" // lalr1.cc:907
{ yylhs.value.as< ElementPtr > () = ElementPtr(new NullElement(ctx.loc2pos(yystack_[0].location))); }
-#line 738 "d2_parser.cc" // lalr1.cc:856
+#line 761 "d2_parser.cc" // lalr1.cc:907
break;
case 25:
-#line 141 "d2_parser.yy" // lalr1.cc:856
+#line 141 "d2_parser.yy" // lalr1.cc:907
{ yylhs.value.as< ElementPtr > () = ctx.stack_.back(); ctx.stack_.pop_back(); }
-#line 744 "d2_parser.cc" // lalr1.cc:856
+#line 767 "d2_parser.cc" // lalr1.cc:907
break;
case 26:
-#line 142 "d2_parser.yy" // lalr1.cc:856
+#line 142 "d2_parser.yy" // lalr1.cc:907
{ yylhs.value.as< ElementPtr > () = ctx.stack_.back(); ctx.stack_.pop_back(); }
-#line 750 "d2_parser.cc" // lalr1.cc:856
+#line 773 "d2_parser.cc" // lalr1.cc:907
break;
case 27:
-#line 145 "d2_parser.yy" // lalr1.cc:856
+#line 145 "d2_parser.yy" // lalr1.cc:907
{
// Push back the JSON value on the stack
ctx.stack_.push_back(yystack_[0].value.as< ElementPtr > ());
}
-#line 759 "d2_parser.cc" // lalr1.cc:856
+#line 782 "d2_parser.cc" // lalr1.cc:907
break;
case 28:
-#line 150 "d2_parser.yy" // lalr1.cc:856
+#line 150 "d2_parser.yy" // lalr1.cc:907
{
// This code is executed when we're about to start parsing
// the content of the map
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.push_back(m);
}
-#line 770 "d2_parser.cc" // lalr1.cc:856
+#line 793 "d2_parser.cc" // lalr1.cc:907
break;
case 29:
-#line 155 "d2_parser.yy" // lalr1.cc:856
+#line 155 "d2_parser.yy" // lalr1.cc:907
{
// map parsing completed. If we ever want to do any wrap up
// (maybe some sanity checking), this would be the best place
// for it.
}
-#line 780 "d2_parser.cc" // lalr1.cc:856
+#line 803 "d2_parser.cc" // lalr1.cc:907
break;
case 30:
-#line 161 "d2_parser.yy" // lalr1.cc:856
+#line 161 "d2_parser.yy" // lalr1.cc:907
{ yylhs.value.as< ElementPtr > () = ctx.stack_.back(); ctx.stack_.pop_back(); }
-#line 786 "d2_parser.cc" // lalr1.cc:856
+#line 809 "d2_parser.cc" // lalr1.cc:907
break;
case 33:
-#line 168 "d2_parser.yy" // lalr1.cc:856
+#line 168 "d2_parser.yy" // lalr1.cc:907
{
// map containing a single entry
ctx.stack_.back()->set(yystack_[2].value.as< std::string > (), yystack_[0].value.as< ElementPtr > ());
}
-#line 795 "d2_parser.cc" // lalr1.cc:856
+#line 818 "d2_parser.cc" // lalr1.cc:907
break;
case 34:
-#line 172 "d2_parser.yy" // lalr1.cc:856
+#line 172 "d2_parser.yy" // lalr1.cc:907
{
// map consisting of a shorter map followed by
// comma and string:value
ctx.stack_.back()->set(yystack_[2].value.as< std::string > (), yystack_[0].value.as< ElementPtr > ());
}
-#line 805 "d2_parser.cc" // lalr1.cc:856
+#line 828 "d2_parser.cc" // lalr1.cc:907
break;
case 35:
-#line 179 "d2_parser.yy" // lalr1.cc:856
+#line 179 "d2_parser.yy" // lalr1.cc:907
{
ElementPtr l(new ListElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.push_back(l);
}
-#line 814 "d2_parser.cc" // lalr1.cc:856
+#line 837 "d2_parser.cc" // lalr1.cc:907
break;
case 36:
-#line 182 "d2_parser.yy" // lalr1.cc:856
+#line 182 "d2_parser.yy" // lalr1.cc:907
{
// list parsing complete. Put any sanity checking here
}
-#line 822 "d2_parser.cc" // lalr1.cc:856
+#line 845 "d2_parser.cc" // lalr1.cc:907
break;
case 39:
-#line 190 "d2_parser.yy" // lalr1.cc:856
+#line 190 "d2_parser.yy" // lalr1.cc:907
{
// List consisting of a single element.
ctx.stack_.back()->add(yystack_[0].value.as< ElementPtr > ());
}
-#line 831 "d2_parser.cc" // lalr1.cc:856
+#line 854 "d2_parser.cc" // lalr1.cc:907
break;
case 40:
-#line 194 "d2_parser.yy" // lalr1.cc:856
+#line 194 "d2_parser.yy" // lalr1.cc:907
{
// List ending with , and a value.
ctx.stack_.back()->add(yystack_[0].value.as< ElementPtr > ());
}
-#line 840 "d2_parser.cc" // lalr1.cc:856
+#line 863 "d2_parser.cc" // lalr1.cc:907
break;
case 41:
-#line 205 "d2_parser.yy" // lalr1.cc:856
+#line 205 "d2_parser.yy" // lalr1.cc:907
{
const std::string& where = ctx.contextName();
const std::string& keyword = yystack_[1].value.as< std::string > ();
error(yystack_[1].location,
"got unexpected keyword \"" + keyword + "\" in " + where + " map.");
}
-#line 851 "d2_parser.cc" // lalr1.cc:856
+#line 874 "d2_parser.cc" // lalr1.cc:907
break;
case 42:
-#line 215 "d2_parser.yy" // lalr1.cc:856
+#line 215 "d2_parser.yy" // lalr1.cc:907
{
// This code is executed when we're about to start parsing
// the content of the map
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.push_back(m);
}
-#line 862 "d2_parser.cc" // lalr1.cc:856
+#line 885 "d2_parser.cc" // lalr1.cc:907
break;
case 43:
-#line 220 "d2_parser.yy" // lalr1.cc:856
+#line 220 "d2_parser.yy" // lalr1.cc:907
{
// map parsing completed. If we ever want to do any wrap up
// (maybe some sanity checking), this would be the best place
// for it.
}
-#line 872 "d2_parser.cc" // lalr1.cc:856
+#line 895 "d2_parser.cc" // lalr1.cc:907
break;
case 52:
-#line 242 "d2_parser.yy" // lalr1.cc:856
+#line 242 "d2_parser.yy" // lalr1.cc:907
{
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("DhcpDdns", m);
ctx.stack_.push_back(m);
ctx.enter(ctx.DHCPDDNS);
}
-#line 883 "d2_parser.cc" // lalr1.cc:856
+#line 906 "d2_parser.cc" // lalr1.cc:907
break;
case 53:
-#line 247 "d2_parser.yy" // lalr1.cc:856
+#line 247 "d2_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
ctx.leave();
}
-#line 892 "d2_parser.cc" // lalr1.cc:856
+#line 915 "d2_parser.cc" // lalr1.cc:907
break;
case 54:
-#line 252 "d2_parser.yy" // lalr1.cc:856
+#line 252 "d2_parser.yy" // lalr1.cc:907
{
// Parse the dhcpddns map
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.push_back(m);
}
-#line 902 "d2_parser.cc" // lalr1.cc:856
+#line 925 "d2_parser.cc" // lalr1.cc:907
break;
case 55:
-#line 256 "d2_parser.yy" // lalr1.cc:856
+#line 256 "d2_parser.yy" // lalr1.cc:907
{
// parsing completed
}
-#line 910 "d2_parser.cc" // lalr1.cc:856
+#line 933 "d2_parser.cc" // lalr1.cc:907
break;
case 69:
-#line 278 "d2_parser.yy" // lalr1.cc:856
+#line 278 "d2_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 918 "d2_parser.cc" // lalr1.cc:856
+#line 941 "d2_parser.cc" // lalr1.cc:907
break;
case 70:
-#line 280 "d2_parser.yy" // lalr1.cc:856
+#line 280 "d2_parser.yy" // lalr1.cc:907
{
ElementPtr s(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("ip-address", s);
ctx.leave();
}
-#line 928 "d2_parser.cc" // lalr1.cc:856
+#line 951 "d2_parser.cc" // lalr1.cc:907
break;
case 71:
-#line 286 "d2_parser.yy" // lalr1.cc:856
+#line 286 "d2_parser.yy" // lalr1.cc:907
{
if (yystack_[0].value.as< int64_t > () <= 0 || yystack_[0].value.as< int64_t > () >= 65536 ) {
error(yystack_[0].location, "port must be greater than zero but less than 65536");
ElementPtr i(new IntElement(yystack_[0].value.as< int64_t > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("port", i);
}
-#line 940 "d2_parser.cc" // lalr1.cc:856
+#line 963 "d2_parser.cc" // lalr1.cc:907
break;
case 72:
-#line 294 "d2_parser.yy" // lalr1.cc:856
+#line 294 "d2_parser.yy" // lalr1.cc:907
{
if (yystack_[0].value.as< int64_t > () <= 0) {
error(yystack_[0].location, "dns-server-timeout must be greater than zero");
ctx.stack_.back()->set("dns-server-timeout", i);
}
}
-#line 953 "d2_parser.cc" // lalr1.cc:856
+#line 976 "d2_parser.cc" // lalr1.cc:907
break;
case 73:
-#line 303 "d2_parser.yy" // lalr1.cc:856
+#line 303 "d2_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NCR_PROTOCOL);
}
-#line 961 "d2_parser.cc" // lalr1.cc:856
+#line 984 "d2_parser.cc" // lalr1.cc:907
break;
case 74:
-#line 305 "d2_parser.yy" // lalr1.cc:856
+#line 305 "d2_parser.yy" // lalr1.cc:907
{
ctx.stack_.back()->set("ncr-protocol", yystack_[0].value.as< ElementPtr > ());
ctx.leave();
}
-#line 970 "d2_parser.cc" // lalr1.cc:856
+#line 993 "d2_parser.cc" // lalr1.cc:907
break;
case 75:
-#line 311 "d2_parser.yy" // lalr1.cc:856
+#line 311 "d2_parser.yy" // lalr1.cc:907
{ yylhs.value.as< ElementPtr > () = ElementPtr(new StringElement("UDP", ctx.loc2pos(yystack_[0].location))); }
-#line 976 "d2_parser.cc" // lalr1.cc:856
+#line 999 "d2_parser.cc" // lalr1.cc:907
break;
case 76:
-#line 312 "d2_parser.yy" // lalr1.cc:856
+#line 312 "d2_parser.yy" // lalr1.cc:907
{ yylhs.value.as< ElementPtr > () = ElementPtr(new StringElement("TCP", ctx.loc2pos(yystack_[0].location))); }
-#line 982 "d2_parser.cc" // lalr1.cc:856
+#line 1005 "d2_parser.cc" // lalr1.cc:907
break;
case 77:
-#line 315 "d2_parser.yy" // lalr1.cc:856
+#line 315 "d2_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NCR_FORMAT);
}
-#line 990 "d2_parser.cc" // lalr1.cc:856
+#line 1013 "d2_parser.cc" // lalr1.cc:907
break;
case 78:
-#line 317 "d2_parser.yy" // lalr1.cc:856
+#line 317 "d2_parser.yy" // lalr1.cc:907
{
ElementPtr json(new StringElement("JSON", ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("ncr-format", json);
ctx.leave();
}
-#line 1000 "d2_parser.cc" // lalr1.cc:856
+#line 1023 "d2_parser.cc" // lalr1.cc:907
break;
case 79:
-#line 323 "d2_parser.yy" // lalr1.cc:856
+#line 323 "d2_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 1008 "d2_parser.cc" // lalr1.cc:856
+#line 1031 "d2_parser.cc" // lalr1.cc:907
break;
case 80:
-#line 325 "d2_parser.yy" // lalr1.cc:856
+#line 325 "d2_parser.yy" // lalr1.cc:907
{
ElementPtr parent = ctx.stack_.back();
ElementPtr user_context = yystack_[0].value.as< ElementPtr > ();
parent->set("user-context", user_context);
ctx.leave();
}
-#line 1035 "d2_parser.cc" // lalr1.cc:856
+#line 1058 "d2_parser.cc" // lalr1.cc:907
break;
case 81:
-#line 348 "d2_parser.yy" // lalr1.cc:856
+#line 348 "d2_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 1043 "d2_parser.cc" // lalr1.cc:856
+#line 1066 "d2_parser.cc" // lalr1.cc:907
break;
case 82:
-#line 350 "d2_parser.yy" // lalr1.cc:856
+#line 350 "d2_parser.yy" // lalr1.cc:907
{
ElementPtr parent = ctx.stack_.back();
ElementPtr user_context(new MapElement(ctx.loc2pos(yystack_[3].location)));
parent->set("user-context", user_context);
ctx.leave();
}
-#line 1072 "d2_parser.cc" // lalr1.cc:856
+#line 1095 "d2_parser.cc" // lalr1.cc:907
break;
case 83:
-#line 375 "d2_parser.yy" // lalr1.cc:856
+#line 375 "d2_parser.yy" // lalr1.cc:907
{
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("forward-ddns", m);
ctx.stack_.push_back(m);
ctx.enter(ctx.FORWARD_DDNS);
}
-#line 1083 "d2_parser.cc" // lalr1.cc:856
+#line 1106 "d2_parser.cc" // lalr1.cc:907
break;
case 84:
-#line 380 "d2_parser.yy" // lalr1.cc:856
+#line 380 "d2_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
ctx.leave();
}
-#line 1092 "d2_parser.cc" // lalr1.cc:856
+#line 1115 "d2_parser.cc" // lalr1.cc:907
break;
case 85:
-#line 385 "d2_parser.yy" // lalr1.cc:856
+#line 385 "d2_parser.yy" // lalr1.cc:907
{
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("reverse-ddns", m);
ctx.stack_.push_back(m);
ctx.enter(ctx.REVERSE_DDNS);
}
-#line 1103 "d2_parser.cc" // lalr1.cc:856
+#line 1126 "d2_parser.cc" // lalr1.cc:907
break;
case 86:
-#line 390 "d2_parser.yy" // lalr1.cc:856
+#line 390 "d2_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
ctx.leave();
}
-#line 1112 "d2_parser.cc" // lalr1.cc:856
+#line 1135 "d2_parser.cc" // lalr1.cc:907
break;
case 93:
-#line 409 "d2_parser.yy" // lalr1.cc:856
+#line 409 "d2_parser.yy" // lalr1.cc:907
{
ElementPtr l(new ListElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("ddns-domains", l);
ctx.stack_.push_back(l);
ctx.enter(ctx.DDNS_DOMAINS);
}
-#line 1123 "d2_parser.cc" // lalr1.cc:856
+#line 1146 "d2_parser.cc" // lalr1.cc:907
break;
case 94:
-#line 414 "d2_parser.yy" // lalr1.cc:856
+#line 414 "d2_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
ctx.leave();
}
-#line 1132 "d2_parser.cc" // lalr1.cc:856
+#line 1155 "d2_parser.cc" // lalr1.cc:907
break;
case 95:
-#line 419 "d2_parser.yy" // lalr1.cc:856
+#line 419 "d2_parser.yy" // lalr1.cc:907
{
ElementPtr l(new ListElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.push_back(l);
}
-#line 1141 "d2_parser.cc" // lalr1.cc:856
+#line 1164 "d2_parser.cc" // lalr1.cc:907
break;
case 96:
-#line 422 "d2_parser.yy" // lalr1.cc:856
+#line 422 "d2_parser.yy" // lalr1.cc:907
{
// parsing completed
}
-#line 1149 "d2_parser.cc" // lalr1.cc:856
+#line 1172 "d2_parser.cc" // lalr1.cc:907
break;
case 101:
-#line 434 "d2_parser.yy" // lalr1.cc:856
+#line 434 "d2_parser.yy" // lalr1.cc:907
{
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->add(m);
ctx.stack_.push_back(m);
}
-#line 1159 "d2_parser.cc" // lalr1.cc:856
+#line 1182 "d2_parser.cc" // lalr1.cc:907
break;
case 102:
-#line 438 "d2_parser.yy" // lalr1.cc:856
+#line 438 "d2_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
}
-#line 1167 "d2_parser.cc" // lalr1.cc:856
+#line 1190 "d2_parser.cc" // lalr1.cc:907
break;
case 103:
-#line 442 "d2_parser.yy" // lalr1.cc:856
+#line 442 "d2_parser.yy" // lalr1.cc:907
{
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.push_back(m);
}
-#line 1176 "d2_parser.cc" // lalr1.cc:856
+#line 1199 "d2_parser.cc" // lalr1.cc:907
break;
case 104:
-#line 445 "d2_parser.yy" // lalr1.cc:856
+#line 445 "d2_parser.yy" // lalr1.cc:907
{
// parsing completed
}
-#line 1184 "d2_parser.cc" // lalr1.cc:856
+#line 1207 "d2_parser.cc" // lalr1.cc:907
break;
case 113:
-#line 462 "d2_parser.yy" // lalr1.cc:856
+#line 462 "d2_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 1192 "d2_parser.cc" // lalr1.cc:856
+#line 1215 "d2_parser.cc" // lalr1.cc:907
break;
case 114:
-#line 464 "d2_parser.yy" // lalr1.cc:856
+#line 464 "d2_parser.yy" // lalr1.cc:907
{
if (yystack_[0].value.as< std::string > () == "") {
error(yystack_[1].location, "Ddns domain name cannot be blank");
ctx.stack_.back()->set("name", name);
ctx.leave();
}
-#line 1206 "d2_parser.cc" // lalr1.cc:856
+#line 1229 "d2_parser.cc" // lalr1.cc:907
break;
case 115:
-#line 474 "d2_parser.yy" // lalr1.cc:856
+#line 474 "d2_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 1214 "d2_parser.cc" // lalr1.cc:856
+#line 1237 "d2_parser.cc" // lalr1.cc:907
break;
case 116:
-#line 476 "d2_parser.yy" // lalr1.cc:856
+#line 476 "d2_parser.yy" // lalr1.cc:907
{
ElementPtr elem(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ElementPtr name(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("key-name", name);
ctx.leave();
}
-#line 1225 "d2_parser.cc" // lalr1.cc:856
+#line 1248 "d2_parser.cc" // lalr1.cc:907
break;
case 117:
-#line 486 "d2_parser.yy" // lalr1.cc:856
+#line 486 "d2_parser.yy" // lalr1.cc:907
{
ElementPtr l(new ListElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("dns-servers", l);
ctx.stack_.push_back(l);
ctx.enter(ctx.DNS_SERVERS);
}
-#line 1236 "d2_parser.cc" // lalr1.cc:856
+#line 1259 "d2_parser.cc" // lalr1.cc:907
break;
case 118:
-#line 491 "d2_parser.yy" // lalr1.cc:856
+#line 491 "d2_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
ctx.leave();
}
-#line 1245 "d2_parser.cc" // lalr1.cc:856
+#line 1268 "d2_parser.cc" // lalr1.cc:907
break;
case 119:
-#line 496 "d2_parser.yy" // lalr1.cc:856
+#line 496 "d2_parser.yy" // lalr1.cc:907
{
ElementPtr l(new ListElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.push_back(l);
}
-#line 1254 "d2_parser.cc" // lalr1.cc:856
+#line 1277 "d2_parser.cc" // lalr1.cc:907
break;
case 120:
-#line 499 "d2_parser.yy" // lalr1.cc:856
+#line 499 "d2_parser.yy" // lalr1.cc:907
{
// parsing completed
}
-#line 1262 "d2_parser.cc" // lalr1.cc:856
+#line 1285 "d2_parser.cc" // lalr1.cc:907
break;
case 123:
-#line 507 "d2_parser.yy" // lalr1.cc:856
+#line 507 "d2_parser.yy" // lalr1.cc:907
{
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->add(m);
ctx.stack_.push_back(m);
}
-#line 1272 "d2_parser.cc" // lalr1.cc:856
+#line 1295 "d2_parser.cc" // lalr1.cc:907
break;
case 124:
-#line 511 "d2_parser.yy" // lalr1.cc:856
+#line 511 "d2_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
}
-#line 1280 "d2_parser.cc" // lalr1.cc:856
+#line 1303 "d2_parser.cc" // lalr1.cc:907
break;
case 125:
-#line 515 "d2_parser.yy" // lalr1.cc:856
+#line 515 "d2_parser.yy" // lalr1.cc:907
{
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.push_back(m);
}
-#line 1289 "d2_parser.cc" // lalr1.cc:856
+#line 1312 "d2_parser.cc" // lalr1.cc:907
break;
case 126:
-#line 518 "d2_parser.yy" // lalr1.cc:856
+#line 518 "d2_parser.yy" // lalr1.cc:907
{
// parsing completed
}
-#line 1297 "d2_parser.cc" // lalr1.cc:856
+#line 1320 "d2_parser.cc" // lalr1.cc:907
break;
case 135:
-#line 534 "d2_parser.yy" // lalr1.cc:856
+#line 534 "d2_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 1305 "d2_parser.cc" // lalr1.cc:856
+#line 1328 "d2_parser.cc" // lalr1.cc:907
break;
case 136:
-#line 536 "d2_parser.yy" // lalr1.cc:856
+#line 536 "d2_parser.yy" // lalr1.cc:907
{
if (yystack_[0].value.as< std::string > () != "") {
error(yystack_[1].location, "hostname is not yet supported");
ctx.stack_.back()->set("hostname", name);
ctx.leave();
}
-#line 1319 "d2_parser.cc" // lalr1.cc:856
+#line 1342 "d2_parser.cc" // lalr1.cc:907
break;
case 137:
-#line 546 "d2_parser.yy" // lalr1.cc:856
+#line 546 "d2_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 1327 "d2_parser.cc" // lalr1.cc:856
+#line 1350 "d2_parser.cc" // lalr1.cc:907
break;
case 138:
-#line 548 "d2_parser.yy" // lalr1.cc:856
+#line 548 "d2_parser.yy" // lalr1.cc:907
{
ElementPtr s(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("ip-address", s);
ctx.leave();
}
-#line 1337 "d2_parser.cc" // lalr1.cc:856
+#line 1360 "d2_parser.cc" // lalr1.cc:907
break;
case 139:
-#line 554 "d2_parser.yy" // lalr1.cc:856
+#line 554 "d2_parser.yy" // lalr1.cc:907
{
if (yystack_[0].value.as< int64_t > () <= 0 || yystack_[0].value.as< int64_t > () >= 65536 ) {
error(yystack_[0].location, "port must be greater than zero but less than 65536");
ElementPtr i(new IntElement(yystack_[0].value.as< int64_t > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("port", i);
}
-#line 1349 "d2_parser.cc" // lalr1.cc:856
+#line 1372 "d2_parser.cc" // lalr1.cc:907
break;
case 140:
-#line 568 "d2_parser.yy" // lalr1.cc:856
+#line 568 "d2_parser.yy" // lalr1.cc:907
{
ElementPtr l(new ListElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("tsig-keys", l);
ctx.stack_.push_back(l);
ctx.enter(ctx.TSIG_KEYS);
}
-#line 1360 "d2_parser.cc" // lalr1.cc:856
+#line 1383 "d2_parser.cc" // lalr1.cc:907
break;
case 141:
-#line 573 "d2_parser.yy" // lalr1.cc:856
+#line 573 "d2_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
ctx.leave();
}
-#line 1369 "d2_parser.cc" // lalr1.cc:856
+#line 1392 "d2_parser.cc" // lalr1.cc:907
break;
case 142:
-#line 578 "d2_parser.yy" // lalr1.cc:856
+#line 578 "d2_parser.yy" // lalr1.cc:907
{
ElementPtr l(new ListElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.push_back(l);
}
-#line 1378 "d2_parser.cc" // lalr1.cc:856
+#line 1401 "d2_parser.cc" // lalr1.cc:907
break;
case 143:
-#line 581 "d2_parser.yy" // lalr1.cc:856
+#line 581 "d2_parser.yy" // lalr1.cc:907
{
// parsing completed
}
-#line 1386 "d2_parser.cc" // lalr1.cc:856
+#line 1409 "d2_parser.cc" // lalr1.cc:907
break;
case 148:
-#line 593 "d2_parser.yy" // lalr1.cc:856
+#line 593 "d2_parser.yy" // lalr1.cc:907
{
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->add(m);
ctx.stack_.push_back(m);
}
-#line 1396 "d2_parser.cc" // lalr1.cc:856
+#line 1419 "d2_parser.cc" // lalr1.cc:907
break;
case 149:
-#line 597 "d2_parser.yy" // lalr1.cc:856
+#line 597 "d2_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
}
-#line 1404 "d2_parser.cc" // lalr1.cc:856
+#line 1427 "d2_parser.cc" // lalr1.cc:907
break;
case 150:
-#line 601 "d2_parser.yy" // lalr1.cc:856
+#line 601 "d2_parser.yy" // lalr1.cc:907
{
// Parse tsig key list entry map
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.push_back(m);
}
-#line 1414 "d2_parser.cc" // lalr1.cc:856
+#line 1437 "d2_parser.cc" // lalr1.cc:907
break;
case 151:
-#line 605 "d2_parser.yy" // lalr1.cc:856
+#line 605 "d2_parser.yy" // lalr1.cc:907
{
// parsing completed
}
-#line 1422 "d2_parser.cc" // lalr1.cc:856
+#line 1445 "d2_parser.cc" // lalr1.cc:907
break;
case 161:
-#line 623 "d2_parser.yy" // lalr1.cc:856
+#line 623 "d2_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 1430 "d2_parser.cc" // lalr1.cc:856
+#line 1453 "d2_parser.cc" // lalr1.cc:907
break;
case 162:
-#line 625 "d2_parser.yy" // lalr1.cc:856
+#line 625 "d2_parser.yy" // lalr1.cc:907
{
if (yystack_[0].value.as< std::string > () == "") {
error(yystack_[1].location, "TSIG key name cannot be blank");
ctx.stack_.back()->set("name", name);
ctx.leave();
}
-#line 1444 "d2_parser.cc" // lalr1.cc:856
+#line 1467 "d2_parser.cc" // lalr1.cc:907
break;
case 163:
-#line 635 "d2_parser.yy" // lalr1.cc:856
+#line 635 "d2_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 1452 "d2_parser.cc" // lalr1.cc:856
+#line 1475 "d2_parser.cc" // lalr1.cc:907
break;
case 164:
-#line 637 "d2_parser.yy" // lalr1.cc:856
+#line 637 "d2_parser.yy" // lalr1.cc:907
{
if (yystack_[0].value.as< std::string > () == "") {
error(yystack_[1].location, "TSIG key algorithm cannot be blank");
ctx.stack_.back()->set("algorithm", elem);
ctx.leave();
}
-#line 1465 "d2_parser.cc" // lalr1.cc:856
+#line 1488 "d2_parser.cc" // lalr1.cc:907
break;
case 165:
-#line 646 "d2_parser.yy" // lalr1.cc:856
+#line 646 "d2_parser.yy" // lalr1.cc:907
{
if (yystack_[0].value.as< int64_t > () < 0 || (yystack_[0].value.as< int64_t > () > 0 && (yystack_[0].value.as< int64_t > () % 8 != 0))) {
error(yystack_[0].location, "TSIG key digest-bits must either be zero or a positive, multiple of eight");
ElementPtr elem(new IntElement(yystack_[0].value.as< int64_t > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("digest-bits", elem);
}
-#line 1477 "d2_parser.cc" // lalr1.cc:856
+#line 1500 "d2_parser.cc" // lalr1.cc:907
break;
case 166:
-#line 654 "d2_parser.yy" // lalr1.cc:856
+#line 654 "d2_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 1485 "d2_parser.cc" // lalr1.cc:856
+#line 1508 "d2_parser.cc" // lalr1.cc:907
break;
case 167:
-#line 656 "d2_parser.yy" // lalr1.cc:856
+#line 656 "d2_parser.yy" // lalr1.cc:907
{
if (yystack_[0].value.as< std::string > () == "") {
error(yystack_[1].location, "TSIG key secret cannot be blank");
ctx.stack_.back()->set("secret", elem);
ctx.leave();
}
-#line 1498 "d2_parser.cc" // lalr1.cc:856
+#line 1521 "d2_parser.cc" // lalr1.cc:907
break;
case 168:
-#line 669 "d2_parser.yy" // lalr1.cc:856
+#line 669 "d2_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 1506 "d2_parser.cc" // lalr1.cc:856
+#line 1529 "d2_parser.cc" // lalr1.cc:907
break;
case 169:
-#line 671 "d2_parser.yy" // lalr1.cc:856
+#line 671 "d2_parser.yy" // lalr1.cc:907
{
ctx.stack_.back()->set("Dhcp6", yystack_[0].value.as< ElementPtr > ());
ctx.leave();
}
-#line 1515 "d2_parser.cc" // lalr1.cc:856
+#line 1538 "d2_parser.cc" // lalr1.cc:907
break;
case 170:
-#line 676 "d2_parser.yy" // lalr1.cc:856
+#line 676 "d2_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 1523 "d2_parser.cc" // lalr1.cc:856
+#line 1546 "d2_parser.cc" // lalr1.cc:907
break;
case 171:
-#line 678 "d2_parser.yy" // lalr1.cc:856
+#line 678 "d2_parser.yy" // lalr1.cc:907
{
ctx.stack_.back()->set("Dhcp4", yystack_[0].value.as< ElementPtr > ());
ctx.leave();
}
-#line 1532 "d2_parser.cc" // lalr1.cc:856
+#line 1555 "d2_parser.cc" // lalr1.cc:907
break;
case 172:
-#line 683 "d2_parser.yy" // lalr1.cc:856
+#line 683 "d2_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 1540 "d2_parser.cc" // lalr1.cc:856
+#line 1563 "d2_parser.cc" // lalr1.cc:907
break;
case 173:
-#line 685 "d2_parser.yy" // lalr1.cc:856
+#line 685 "d2_parser.yy" // lalr1.cc:907
{
ctx.stack_.back()->set("Control-agent", yystack_[0].value.as< ElementPtr > ());
ctx.leave();
}
-#line 1549 "d2_parser.cc" // lalr1.cc:856
+#line 1572 "d2_parser.cc" // lalr1.cc:907
break;
case 174:
-#line 695 "d2_parser.yy" // lalr1.cc:856
+#line 695 "d2_parser.yy" // lalr1.cc:907
{
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("Logging", m);
ctx.stack_.push_back(m);
ctx.enter(ctx.LOGGING);
}
-#line 1560 "d2_parser.cc" // lalr1.cc:856
+#line 1583 "d2_parser.cc" // lalr1.cc:907
break;
case 175:
-#line 700 "d2_parser.yy" // lalr1.cc:856
+#line 700 "d2_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
ctx.leave();
}
-#line 1569 "d2_parser.cc" // lalr1.cc:856
+#line 1592 "d2_parser.cc" // lalr1.cc:907
break;
case 179:
-#line 717 "d2_parser.yy" // lalr1.cc:856
+#line 717 "d2_parser.yy" // lalr1.cc:907
{
ElementPtr l(new ListElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("loggers", l);
ctx.stack_.push_back(l);
ctx.enter(ctx.LOGGERS);
}
-#line 1580 "d2_parser.cc" // lalr1.cc:856
+#line 1603 "d2_parser.cc" // lalr1.cc:907
break;
case 180:
-#line 722 "d2_parser.yy" // lalr1.cc:856
+#line 722 "d2_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
ctx.leave();
}
-#line 1589 "d2_parser.cc" // lalr1.cc:856
+#line 1612 "d2_parser.cc" // lalr1.cc:907
break;
case 183:
-#line 734 "d2_parser.yy" // lalr1.cc:856
+#line 734 "d2_parser.yy" // lalr1.cc:907
{
ElementPtr l(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->add(l);
ctx.stack_.push_back(l);
}
-#line 1599 "d2_parser.cc" // lalr1.cc:856
+#line 1622 "d2_parser.cc" // lalr1.cc:907
break;
case 184:
-#line 738 "d2_parser.yy" // lalr1.cc:856
+#line 738 "d2_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
}
-#line 1607 "d2_parser.cc" // lalr1.cc:856
+#line 1630 "d2_parser.cc" // lalr1.cc:907
break;
case 194:
-#line 755 "d2_parser.yy" // lalr1.cc:856
+#line 755 "d2_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 1615 "d2_parser.cc" // lalr1.cc:856
+#line 1638 "d2_parser.cc" // lalr1.cc:907
break;
case 195:
-#line 757 "d2_parser.yy" // lalr1.cc:856
+#line 757 "d2_parser.yy" // lalr1.cc:907
{
ElementPtr name(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("name", name);
ctx.leave();
}
-#line 1625 "d2_parser.cc" // lalr1.cc:856
+#line 1648 "d2_parser.cc" // lalr1.cc:907
break;
case 196:
-#line 763 "d2_parser.yy" // lalr1.cc:856
+#line 763 "d2_parser.yy" // lalr1.cc:907
{
ElementPtr dl(new IntElement(yystack_[0].value.as< int64_t > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("debuglevel", dl);
}
-#line 1634 "d2_parser.cc" // lalr1.cc:856
+#line 1657 "d2_parser.cc" // lalr1.cc:907
break;
case 197:
-#line 767 "d2_parser.yy" // lalr1.cc:856
+#line 767 "d2_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 1642 "d2_parser.cc" // lalr1.cc:856
+#line 1665 "d2_parser.cc" // lalr1.cc:907
break;
case 198:
-#line 769 "d2_parser.yy" // lalr1.cc:856
+#line 769 "d2_parser.yy" // lalr1.cc:907
{
ElementPtr sev(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("severity", sev);
ctx.leave();
}
-#line 1652 "d2_parser.cc" // lalr1.cc:856
+#line 1675 "d2_parser.cc" // lalr1.cc:907
break;
case 199:
-#line 775 "d2_parser.yy" // lalr1.cc:856
+#line 775 "d2_parser.yy" // lalr1.cc:907
{
ElementPtr l(new ListElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("output_options", l);
ctx.stack_.push_back(l);
ctx.enter(ctx.OUTPUT_OPTIONS);
}
-#line 1663 "d2_parser.cc" // lalr1.cc:856
+#line 1686 "d2_parser.cc" // lalr1.cc:907
break;
case 200:
-#line 780 "d2_parser.yy" // lalr1.cc:856
+#line 780 "d2_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
ctx.leave();
}
-#line 1672 "d2_parser.cc" // lalr1.cc:856
+#line 1695 "d2_parser.cc" // lalr1.cc:907
break;
case 203:
-#line 789 "d2_parser.yy" // lalr1.cc:856
+#line 789 "d2_parser.yy" // lalr1.cc:907
{
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->add(m);
ctx.stack_.push_back(m);
}
-#line 1682 "d2_parser.cc" // lalr1.cc:856
+#line 1705 "d2_parser.cc" // lalr1.cc:907
break;
case 204:
-#line 793 "d2_parser.yy" // lalr1.cc:856
+#line 793 "d2_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
}
-#line 1690 "d2_parser.cc" // lalr1.cc:856
+#line 1713 "d2_parser.cc" // lalr1.cc:907
break;
case 211:
-#line 807 "d2_parser.yy" // lalr1.cc:856
+#line 807 "d2_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 1698 "d2_parser.cc" // lalr1.cc:856
+#line 1721 "d2_parser.cc" // lalr1.cc:907
break;
case 212:
-#line 809 "d2_parser.yy" // lalr1.cc:856
+#line 809 "d2_parser.yy" // lalr1.cc:907
{
ElementPtr sev(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("output", sev);
ctx.leave();
}
-#line 1708 "d2_parser.cc" // lalr1.cc:856
+#line 1731 "d2_parser.cc" // lalr1.cc:907
break;
case 213:
-#line 815 "d2_parser.yy" // lalr1.cc:856
+#line 815 "d2_parser.yy" // lalr1.cc:907
{
ElementPtr flush(new BoolElement(yystack_[0].value.as< bool > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("flush", flush);
}
-#line 1717 "d2_parser.cc" // lalr1.cc:856
+#line 1740 "d2_parser.cc" // lalr1.cc:907
break;
case 214:
-#line 820 "d2_parser.yy" // lalr1.cc:856
+#line 820 "d2_parser.yy" // lalr1.cc:907
{
ElementPtr maxsize(new IntElement(yystack_[0].value.as< int64_t > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("maxsize", maxsize);
}
-#line 1726 "d2_parser.cc" // lalr1.cc:856
+#line 1749 "d2_parser.cc" // lalr1.cc:907
break;
case 215:
-#line 825 "d2_parser.yy" // lalr1.cc:856
+#line 825 "d2_parser.yy" // lalr1.cc:907
{
ElementPtr maxver(new IntElement(yystack_[0].value.as< int64_t > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("maxver", maxver);
}
-#line 1735 "d2_parser.cc" // lalr1.cc:856
+#line 1758 "d2_parser.cc" // lalr1.cc:907
break;
-#line 1739 "d2_parser.cc" // lalr1.cc:856
+#line 1762 "d2_parser.cc" // lalr1.cc:907
default:
break;
}
}
+#if YY_EXCEPTIONS
catch (const syntax_error& yyexc)
{
error (yyexc);
YYERROR;
}
+#endif // YY_EXCEPTIONS
YY_SYMBOL_PRINT ("-> $$ =", yylhs);
yypop_ (yylen);
yylen = 0;
YY_STACK_PRINT ();
// Shift the result of the reduction.
- yypush_ (YY_NULLPTR, yylhs);
+ yypush_ (YY_NULLPTR, YY_MOVE (yylhs));
}
goto yynewstate;
// Shift the error token.
error_token.state = yyn;
- yypush_ ("Shifting", error_token);
+ yypush_ ("Shifting", YY_MOVE (error_token));
}
goto yynewstate;
return yyresult;
}
+#if YY_EXCEPTIONS
catch (...)
{
YYCDEBUG << "Exception caught: cleaning lookahead and stack\n";
// Do not try to display the values of the reclaimed symbols,
- // as their printer might throw an exception.
+ // as their printers might throw an exception.
if (!yyla.empty ())
yy_destroy_ (YY_NULLPTR, yyla);
}
throw;
}
+#endif // YY_EXCEPTIONS
}
void
const signed char D2Parser::yytable_ninf_ = -1;
- const short int
+ const short
D2Parser::yypact_[] =
{
47, -90, -90, -90, -90, -90, -90, -90, -90, -90,
-90, -90, -89, -90, -90, -90, -90, -90
};
- const short int
+ const short
D2Parser::yydefgoto_[] =
{
-1, 10, 11, 12, 13, 14, 15, 16, 17, 18,
334, 341, 342, 343, 348, 344, 345, 346
};
- const unsigned short int
+ const unsigned short
D2Parser::yytable_[] =
{
70, 106, 105, 122, 121, 137, 136, 21, 32, 22,
0, 0, 309
};
- const short int
+ const short
D2Parser::yycheck_[] =
{
50, 52, 52, 54, 54, 56, 56, 5, 7, 7,
};
#if D2_PARSER_DEBUG
- const unsigned short int
+ const unsigned short
D2Parser::yyrline_[] =
{
0, 120, 120, 120, 121, 121, 122, 122, 123, 123,
#endif // D2_PARSER_DEBUG
-#line 14 "d2_parser.yy" // lalr1.cc:1163
+#line 14 "d2_parser.yy" // lalr1.cc:1218
} } // isc::d2
-#line 2392 "d2_parser.cc" // lalr1.cc:1163
-#line 830 "d2_parser.yy" // lalr1.cc:1164
+#line 2419 "d2_parser.cc" // lalr1.cc:1218
+#line 830 "d2_parser.yy" // lalr1.cc:1219
void
-// A Bison parser, made by GNU Bison 3.0.5.
+// A Bison parser, made by GNU Bison 3.2.1.
// Skeleton interface for Bison LALR(1) parsers in C++
// This special exception was added by the Free Software Foundation in
// version 2.2 of Bison.
+
/**
** \file d2_parser.h
** Define the isc::d2::parser class.
// C++ LALR(1) parser skeleton written by Akim Demaille.
+// Undocumented macros, especially those whose name start with YY_,
+// are private implementation details. Do not rely on them.
+
#ifndef YY_D2_PARSER_D2_PARSER_H_INCLUDED
# define YY_D2_PARSER_D2_PARSER_H_INCLUDED
// // "%code requires" blocks.
-#line 17 "d2_parser.yy" // lalr1.cc:379
+#line 17 "d2_parser.yy" // lalr1.cc:404
#include <string>
#include <cc/data.h>
using namespace isc::data;
using namespace std;
-#line 56 "d2_parser.h" // lalr1.cc:379
+#line 60 "d2_parser.h" // lalr1.cc:404
# include <cassert>
# include <cstdlib> // std::abort
# include <stdexcept>
# include <string>
# include <vector>
-# include "stack.hh"
+
+// Support move semantics when possible.
+#if defined __cplusplus && 201103L <= __cplusplus
+# define YY_MOVE std::move
+# define YY_MOVE_OR_COPY move
+# define YY_MOVE_REF(Type) Type&&
+# define YY_RVREF(Type) Type&&
+# define YY_COPY(Type) Type
+#else
+# define YY_MOVE
+# define YY_MOVE_OR_COPY copy
+# define YY_MOVE_REF(Type) Type&
+# define YY_RVREF(Type) const Type&
+# define YY_COPY(Type) const Type&
+#endif
# include "location.hh"
#include <typeinfo>
#ifndef YYASSERT
# define YY_ATTRIBUTE_UNUSED YY_ATTRIBUTE ((__unused__))
#endif
-#if !defined _Noreturn \
- && (!defined __STDC_VERSION__ || __STDC_VERSION__ < 201112)
-# if defined _MSC_VER && 1200 <= _MSC_VER
-# define _Noreturn __declspec (noreturn)
-# else
-# define _Noreturn YY_ATTRIBUTE ((__noreturn__))
-# endif
-#endif
-
/* Suppress unused-variable warnings by "using" E. */
#if ! defined lint || defined __GNUC__
# define YYUSE(E) ((void) (E))
# define YYUSE(E) /* empty */
#endif
-#if defined __GNUC__ && 407 <= __GNUC__ * 100 + __GNUC_MINOR__
+#if defined __GNUC__ && ! defined __ICC && 407 <= __GNUC__ * 100 + __GNUC_MINOR__
/* Suppress an incorrect diagnostic about yylval being uninitialized. */
# define YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN \
_Pragma ("GCC diagnostic push") \
# define YY_INITIAL_VALUE(Value) /* Nothing. */
#endif
+# ifndef YY_NULLPTR
+# if defined __cplusplus
+# if 201103L <= __cplusplus
+# define YY_NULLPTR nullptr
+# else
+# define YY_NULLPTR 0
+# endif
+# else
+# define YY_NULLPTR ((void*)0)
+# endif
+# endif
+
/* Debug traces. */
#ifndef D2_PARSER_DEBUG
# if defined YYDEBUG
# endif /* ! defined YYDEBUG */
#endif /* ! defined D2_PARSER_DEBUG */
-#line 14 "d2_parser.yy" // lalr1.cc:379
+#line 14 "d2_parser.yy" // lalr1.cc:404
namespace isc { namespace d2 {
-#line 141 "d2_parser.h" // lalr1.cc:379
+#line 162 "d2_parser.h" // lalr1.cc:404
+
+ /// A stack with random access from its top.
+ template <typename T, typename S = std::vector<T> >
+ class stack
+ {
+ public:
+ // Hide our reversed order.
+ typedef typename S::reverse_iterator iterator;
+ typedef typename S::const_reverse_iterator const_iterator;
+ typedef typename S::size_type size_type;
+
+ stack (size_type n = 200)
+ : seq_ (n)
+ {}
+
+ /// Random access.
+ ///
+ /// Index 0 returns the topmost element.
+ T&
+ operator[] (size_type i)
+ {
+ return seq_[size () - 1 - i];
+ }
+
+ /// Random access.
+ ///
+ /// Index 0 returns the topmost element.
+ T&
+ operator[] (int i)
+ {
+ return operator[] (size_type (i));
+ }
+
+ /// Random access.
+ ///
+ /// Index 0 returns the topmost element.
+ const T&
+ operator[] (size_type i) const
+ {
+ return seq_[size () - 1 - i];
+ }
+
+ /// Random access.
+ ///
+ /// Index 0 returns the topmost element.
+ const T&
+ operator[] (int i) const
+ {
+ return operator[] (size_type (i));
+ }
+
+ /// Steal the contents of \a t.
+ ///
+ /// Close to move-semantics.
+ void
+ push (YY_MOVE_REF (T) t)
+ {
+ seq_.push_back (T ());
+ operator[](0).move (t);
+ }
+
+ void
+ pop (int n = 1)
+ {
+ for (; 0 < n; --n)
+ seq_.pop_back ();
+ }
+
+ void
+ clear ()
+ {
+ seq_.clear ();
+ }
+
+ size_type
+ size () const
+ {
+ return seq_.size ();
+ }
+
+ const_iterator
+ begin () const
+ {
+ return seq_.rbegin ();
+ }
+
+ const_iterator
+ end () const
+ {
+ return seq_.rend ();
+ }
+
+ private:
+ stack (const stack&);
+ stack& operator= (const stack&);
+ /// The wrapped container.
+ S seq_;
+ };
+
+ /// Present a slice of the top of a stack.
+ template <typename T, typename S = stack<T> >
+ class slice
+ {
+ public:
+ slice (const S& stack, int range)
+ : stack_ (stack)
+ , range_ (range)
+ {}
+
+ const T&
+ operator[] (int i) const
+ {
+ return stack_[range_ - i];
+ }
+
+ private:
+ const S& stack_;
+ int range_;
+ };
/// Empty construction.
variant ()
- : yytypeid_ (YY_NULLPTR)
+ : yybuffer_ ()
+ , yytypeid_ (YY_NULLPTR)
{}
/// Construct and fill.
template <typename T>
- variant (const T& t)
+ variant (YY_RVREF (T) t)
: yytypeid_ (&typeid (T))
{
YYASSERT (sizeof (T) <= S);
- new (yyas_<T> ()) T (t);
+ new (yyas_<T> ()) T (YY_MOVE (t));
}
/// Destruction, allowed only if empty.
/// Instantiate an empty \a T in here.
template <typename T>
T&
- build ()
+ emplace ()
{
YYASSERT (!yytypeid_);
YYASSERT (sizeof (T) <= S);
yytypeid_ = & typeid (T);
- return *new (yyas_<T> ()) T;
+ return *new (yyas_<T> ()) T ();
}
+# if defined __cplusplus && 201103L <= __cplusplus
+ /// Instantiate a \a T in here from \a t.
+ template <typename T, typename U>
+ T&
+ emplace (U&& u)
+ {
+ YYASSERT (!yytypeid_);
+ YYASSERT (sizeof (T) <= S);
+ yytypeid_ = & typeid (T);
+ return *new (yyas_<T> ()) T (std::forward <U>(u));
+ }
+# else
/// Instantiate a \a T in here from \a t.
template <typename T>
T&
- build (const T& t)
+ emplace (const T& t)
{
YYASSERT (!yytypeid_);
YYASSERT (sizeof (T) <= S);
yytypeid_ = & typeid (T);
return *new (yyas_<T> ()) T (t);
}
+# endif
+
+ /// Instantiate an empty \a T in here.
+ /// Obsolete, use emplace.
+ template <typename T>
+ T&
+ build ()
+ {
+ return emplace<T> ();
+ }
+
+ /// Instantiate a \a T in here from \a t.
+ /// Obsolete, use emplace.
+ template <typename T>
+ T&
+ build (const T& t)
+ {
+ return emplace<T> (t);
+ }
/// Accessor to a built \a T.
template <typename T>
T&
as ()
{
+ YYASSERT (yytypeid_);
YYASSERT (*yytypeid_ == typeid (T));
YYASSERT (sizeof (T) <= S);
return *yyas_<T> ();
const T&
as () const
{
+ YYASSERT (yytypeid_);
YYASSERT (*yytypeid_ == typeid (T));
YYASSERT (sizeof (T) <= S);
return *yyas_<T> ();
/// Both variants must be built beforehand, because swapping the actual
/// data requires reading it (with as()), and this is not possible on
/// unconstructed variants: it would require some dynamic testing, which
- /// should not be the variant's responsability.
+ /// should not be the variant's responsibility.
/// Swapping between built and (possibly) non-built is done with
/// variant::move ().
template <typename T>
void
move (self_type& other)
{
- build<T> ();
+# if defined __cplusplus && 201103L <= __cplusplus
+ emplace<T> (std::move (other.as<T> ()));
+# else
+ emplace<T> ();
swap<T> (other);
+# endif
+ other.destroy<T> ();
+ }
+
+# if defined __cplusplus && 201103L <= __cplusplus
+ /// Move the content of \a other to this.
+ template <typename T>
+ void
+ move (self_type&& other)
+ {
+ emplace<T> (std::move (other.as<T> ()));
other.destroy<T> ();
}
+#endif
/// Copy the content of \a other to this.
template <typename T>
void
copy (const self_type& other)
{
- build<T> (other.as<T> ());
+ emplace<T> (other.as<T> ());
}
/// Destroy the stored \a T.
private:
/// Prohibit blind copies.
- self_type& operator=(const self_type&);
+ self_type& operator= (const self_type&);
variant (const self_type&);
/// Accessor to raw memory as \a T.
// value
// map_value
// ncr_protocol_value
- char dummy1[sizeof(ElementPtr)];
+ char dummy1[sizeof (ElementPtr)];
// "boolean"
- char dummy2[sizeof(bool)];
+ char dummy2[sizeof (bool)];
// "floating point"
- char dummy3[sizeof(double)];
+ char dummy3[sizeof (double)];
// "integer"
- char dummy4[sizeof(int64_t)];
+ char dummy4[sizeof (int64_t)];
// "constant string"
- char dummy5[sizeof(std::string)];
+ char dummy5[sizeof (std::string)];
};
/// Symbol semantic values.
- typedef variant<sizeof(union_type)> semantic_type;
+ typedef variant<sizeof (union_type)> semantic_type;
#else
typedef D2_PARSER_STYPE semantic_type;
#endif
/// A complete symbol.
///
/// Expects its Base type to provide access to the symbol type
- /// via type_get().
+ /// via type_get ().
///
/// Provide access to semantic value and location.
template <typename Base>
/// Default constructor.
basic_symbol ();
- /// Copy constructor.
- basic_symbol (const basic_symbol& other);
-
- /// Constructor for valueless symbols, and symbols from each type.
-
- basic_symbol (typename Base::kind_type t, const location_type& l);
+ /// Move or copy constructor.
+ basic_symbol (YY_RVREF (basic_symbol) other);
- basic_symbol (typename Base::kind_type t, const ElementPtr v, const location_type& l);
-
- basic_symbol (typename Base::kind_type t, const bool v, const location_type& l);
-
- basic_symbol (typename Base::kind_type t, const double v, const location_type& l);
-
- basic_symbol (typename Base::kind_type t, const int64_t v, const location_type& l);
-
- basic_symbol (typename Base::kind_type t, const std::string v, const location_type& l);
+ /// Constructor for valueless symbols, and symbols from each type.
+ basic_symbol (typename Base::kind_type t, YY_RVREF (location_type) l);
+ basic_symbol (typename Base::kind_type t, YY_RVREF (ElementPtr) v, YY_RVREF (location_type) l);
+ basic_symbol (typename Base::kind_type t, YY_RVREF (bool) v, YY_RVREF (location_type) l);
+ basic_symbol (typename Base::kind_type t, YY_RVREF (double) v, YY_RVREF (location_type) l);
+ basic_symbol (typename Base::kind_type t, YY_RVREF (int64_t) v, YY_RVREF (location_type) l);
+ basic_symbol (typename Base::kind_type t, YY_RVREF (std::string) v, YY_RVREF (location_type) l);
- /// Constructor for symbols with semantic value.
- basic_symbol (typename Base::kind_type t,
- const semantic_type& v,
- const location_type& l);
/// Destroy the symbol.
~basic_symbol ();
location_type location;
private:
+#if !defined __cplusplus || __cplusplus < 201103L
/// Assignment operator.
basic_symbol& operator= (const basic_symbol& other);
+#endif
};
/// Type access provider for token (enum) based symbols.
/// "External" symbols: returned by the scanner.
typedef basic_symbol<by_type> symbol_type;
+ /// Build a parser object.
+ D2Parser (isc::d2::D2ParserContext& ctx_yyarg);
+ virtual ~D2Parser ();
+
+ /// Parse. An alias for parse ().
+ /// \returns 0 iff parsing succeeded.
+ int operator() ();
+
+ /// Parse.
+ /// \returns 0 iff parsing succeeded.
+ virtual int parse ();
+
+#if D2_PARSER_DEBUG
+ /// The current debugging stream.
+ std::ostream& debug_stream () const YY_ATTRIBUTE_PURE;
+ /// Set the current debugging stream.
+ void set_debug_stream (std::ostream &);
+
+ /// Type for debugging levels.
+ typedef int debug_level_type;
+ /// The current debugging level.
+ debug_level_type debug_level () const YY_ATTRIBUTE_PURE;
+ /// Set the current debugging level.
+ void set_debug_level (debug_level_type l);
+#endif
+
+ /// Report a syntax error.
+ /// \param loc where the syntax error is found.
+ /// \param msg a description of the syntax error.
+ virtual void error (const location_type& loc, const std::string& msg);
+
+ /// Report a syntax error.
+ void error (const syntax_error& err);
+
// Symbol constructors declarations.
- static inline
+ static
symbol_type
- make_END (const location_type& l);
+ make_END (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_COMMA (const location_type& l);
+ make_COMMA (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_COLON (const location_type& l);
+ make_COLON (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_LSQUARE_BRACKET (const location_type& l);
+ make_LSQUARE_BRACKET (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_RSQUARE_BRACKET (const location_type& l);
+ make_RSQUARE_BRACKET (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_LCURLY_BRACKET (const location_type& l);
+ make_LCURLY_BRACKET (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_RCURLY_BRACKET (const location_type& l);
+ make_RCURLY_BRACKET (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_NULL_TYPE (const location_type& l);
+ make_NULL_TYPE (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_DHCP6 (const location_type& l);
+ make_DHCP6 (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_DHCP4 (const location_type& l);
+ make_DHCP4 (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_CONTROL_AGENT (const location_type& l);
+ make_CONTROL_AGENT (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_DHCPDDNS (const location_type& l);
+ make_DHCPDDNS (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_IP_ADDRESS (const location_type& l);
+ make_IP_ADDRESS (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_PORT (const location_type& l);
+ make_PORT (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_DNS_SERVER_TIMEOUT (const location_type& l);
+ make_DNS_SERVER_TIMEOUT (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_NCR_PROTOCOL (const location_type& l);
+ make_NCR_PROTOCOL (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_UDP (const location_type& l);
+ make_UDP (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_TCP (const location_type& l);
+ make_TCP (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_NCR_FORMAT (const location_type& l);
+ make_NCR_FORMAT (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_JSON (const location_type& l);
+ make_JSON (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_USER_CONTEXT (const location_type& l);
+ make_USER_CONTEXT (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_COMMENT (const location_type& l);
+ make_COMMENT (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_FORWARD_DDNS (const location_type& l);
+ make_FORWARD_DDNS (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_REVERSE_DDNS (const location_type& l);
+ make_REVERSE_DDNS (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_DDNS_DOMAINS (const location_type& l);
+ make_DDNS_DOMAINS (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_KEY_NAME (const location_type& l);
+ make_KEY_NAME (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_DNS_SERVERS (const location_type& l);
+ make_DNS_SERVERS (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_HOSTNAME (const location_type& l);
+ make_HOSTNAME (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_TSIG_KEYS (const location_type& l);
+ make_TSIG_KEYS (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_ALGORITHM (const location_type& l);
+ make_ALGORITHM (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_DIGEST_BITS (const location_type& l);
+ make_DIGEST_BITS (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_SECRET (const location_type& l);
+ make_SECRET (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_LOGGING (const location_type& l);
+ make_LOGGING (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_LOGGERS (const location_type& l);
+ make_LOGGERS (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_NAME (const location_type& l);
+ make_NAME (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_OUTPUT_OPTIONS (const location_type& l);
+ make_OUTPUT_OPTIONS (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_OUTPUT (const location_type& l);
+ make_OUTPUT (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_DEBUGLEVEL (const location_type& l);
+ make_DEBUGLEVEL (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_SEVERITY (const location_type& l);
+ make_SEVERITY (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_FLUSH (const location_type& l);
+ make_FLUSH (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_MAXSIZE (const location_type& l);
+ make_MAXSIZE (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_MAXVER (const location_type& l);
+ make_MAXVER (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_TOPLEVEL_JSON (const location_type& l);
+ make_TOPLEVEL_JSON (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_TOPLEVEL_DHCPDDNS (const location_type& l);
+ make_TOPLEVEL_DHCPDDNS (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_SUB_DHCPDDNS (const location_type& l);
+ make_SUB_DHCPDDNS (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_SUB_TSIG_KEY (const location_type& l);
+ make_SUB_TSIG_KEY (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_SUB_TSIG_KEYS (const location_type& l);
+ make_SUB_TSIG_KEYS (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_SUB_DDNS_DOMAIN (const location_type& l);
+ make_SUB_DDNS_DOMAIN (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_SUB_DDNS_DOMAINS (const location_type& l);
+ make_SUB_DDNS_DOMAINS (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_SUB_DNS_SERVER (const location_type& l);
+ make_SUB_DNS_SERVER (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_SUB_DNS_SERVERS (const location_type& l);
+ make_SUB_DNS_SERVERS (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_STRING (const std::string& v, const location_type& l);
+ make_STRING (YY_COPY (std::string) v, YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_INTEGER (const int64_t& v, const location_type& l);
+ make_INTEGER (YY_COPY (int64_t) v, YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_FLOAT (const double& v, const location_type& l);
+ make_FLOAT (YY_COPY (double) v, YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_BOOLEAN (const bool& v, const location_type& l);
+ make_BOOLEAN (YY_COPY (bool) v, YY_COPY (location_type) l);
- /// Build a parser object.
- D2Parser (isc::d2::D2ParserContext& ctx_yyarg);
- virtual ~D2Parser ();
-
- /// Parse.
- /// \returns 0 iff parsing succeeded.
- virtual int parse ();
-
-#if D2_PARSER_DEBUG
- /// The current debugging stream.
- std::ostream& debug_stream () const YY_ATTRIBUTE_PURE;
- /// Set the current debugging stream.
- void set_debug_stream (std::ostream &);
-
- /// Type for debugging levels.
- typedef int debug_level_type;
- /// The current debugging level.
- debug_level_type debug_level () const YY_ATTRIBUTE_PURE;
- /// Set the current debugging level.
- void set_debug_level (debug_level_type l);
-#endif
-
- /// Report a syntax error.
- /// \param loc where the syntax error is found.
- /// \param msg a description of the syntax error.
- virtual void error (const location_type& loc, const std::string& msg);
-
- /// Report a syntax error.
- void error (const syntax_error& err);
private:
/// This class is not copyable.
// Tables.
// YYPACT[STATE-NUM] -- Index in YYTABLE of the portion describing
// STATE-NUM.
- static const short int yypact_[];
+ static const short yypact_[];
// YYDEFACT[STATE-NUM] -- Default reduction number in state STATE-NUM.
// Performed when YYTABLE does not specify something else to do. Zero
static const signed char yypgoto_[];
// YYDEFGOTO[NTERM-NUM].
- static const short int yydefgoto_[];
+ static const short yydefgoto_[];
// YYTABLE[YYPACT[STATE-NUM]] -- What to do in state STATE-NUM. If
// positive, shift that token. If negative, reduce the rule whose
// number is the opposite. If YYTABLE_NINF, syntax error.
- static const unsigned short int yytable_[];
+ static const unsigned short yytable_[];
- static const short int yycheck_[];
+ static const short yycheck_[];
// YYSTOS[STATE-NUM] -- The (internal number of the) accessing
// symbol of state STATE-NUM.
static const char* const yytname_[];
#if D2_PARSER_DEBUG
// YYRLINE[YYN] -- Source line where rule number YYN was defined.
- static const unsigned short int yyrline_[];
+ static const unsigned short yyrline_[];
/// Report on the debug stream that the rule \a r is going to be reduced.
virtual void yy_reduce_print_ (int r);
/// Print the state stack on the debug stream.
virtual void yystack_print_ ();
- // Debugging.
+ /// Debugging level.
int yydebug_;
+ /// Debug stream.
std::ostream* yycdebug_;
/// \brief Display a symbol type, value and location.
typedef basic_symbol<by_state> super_type;
/// Construct an empty symbol.
stack_symbol_type ();
- /// Copy construct.
- stack_symbol_type (const stack_symbol_type& that);
+ /// Move or copy construction.
+ stack_symbol_type (YY_RVREF (stack_symbol_type) that);
/// Steal the contents from \a sym to build this.
- stack_symbol_type (state_type s, symbol_type& sym);
- /// Assignment, needed by push_back.
- stack_symbol_type& operator= (const stack_symbol_type& that);
+ stack_symbol_type (state_type s, YY_MOVE_REF (symbol_type) sym);
+#if !defined __cplusplus || __cplusplus < 201103L
+ /// Assignment, needed by push_back by some old implementations.
+ /// Moves the contents of that.
+ stack_symbol_type& operator= (stack_symbol_type& that);
+#endif
};
/// Stack type.
/// Push a new state on the stack.
/// \param m a debug message to display
/// if null, no trace is output.
- /// \param s the symbol
+ /// \param sym the symbol
/// \warning the contents of \a s.value is stolen.
- void yypush_ (const char* m, stack_symbol_type& s);
+ void yypush_ (const char* m, YY_MOVE_REF (stack_symbol_type) sym);
/// Push a new look ahead token on the state on the stack.
/// \param m a debug message to display
/// if null, no trace is output.
/// \param s the state
/// \param sym the symbol (for its value and location).
- /// \warning the contents of \a s.value is stolen.
- void yypush_ (const char* m, state_type s, symbol_type& sym);
+ /// \warning the contents of \a sym.value is stolen.
+ void yypush_ (const char* m, state_type s, YY_MOVE_REF (symbol_type) sym);
- /// Pop \a n symbols the three stacks.
- void yypop_ (unsigned n = 1);
+ /// Pop \a n symbols from the stack.
+ void yypop_ (int n = 1);
/// Constants.
enum
template <typename Base>
D2Parser::basic_symbol<Base>::basic_symbol ()
: value ()
+ , location ()
{}
template <typename Base>
- D2Parser::basic_symbol<Base>::basic_symbol (const basic_symbol& other)
- : Base (other)
+ D2Parser::basic_symbol<Base>::basic_symbol (YY_RVREF (basic_symbol) other)
+ : Base (YY_MOVE (other))
, value ()
- , location (other.location)
+ , location (YY_MOVE (other.location))
{
switch (other.type_get ())
{
case 68: // value
case 72: // map_value
case 96: // ncr_protocol_value
- value.copy< ElementPtr > (other.value);
+ value.YY_MOVE_OR_COPY< ElementPtr > (YY_MOVE (other.value));
break;
case 56: // "boolean"
- value.copy< bool > (other.value);
+ value.YY_MOVE_OR_COPY< bool > (YY_MOVE (other.value));
break;
case 55: // "floating point"
- value.copy< double > (other.value);
+ value.YY_MOVE_OR_COPY< double > (YY_MOVE (other.value));
break;
case 54: // "integer"
- value.copy< int64_t > (other.value);
+ value.YY_MOVE_OR_COPY< int64_t > (YY_MOVE (other.value));
break;
case 53: // "constant string"
- value.copy< std::string > (other.value);
+ value.YY_MOVE_OR_COPY< std::string > (YY_MOVE (other.value));
break;
default:
}
- template <typename Base>
- D2Parser::basic_symbol<Base>::basic_symbol (typename Base::kind_type t, const semantic_type& v, const location_type& l)
- : Base (t)
- , value ()
- , location (l)
- {
- (void) v;
- switch (this->type_get ())
- {
- case 68: // value
- case 72: // map_value
- case 96: // ncr_protocol_value
- value.copy< ElementPtr > (v);
- break;
-
- case 56: // "boolean"
- value.copy< bool > (v);
- break;
-
- case 55: // "floating point"
- value.copy< double > (v);
- break;
-
- case 54: // "integer"
- value.copy< int64_t > (v);
- break;
-
- case 53: // "constant string"
- value.copy< std::string > (v);
- break;
-
- default:
- break;
- }
-}
-
// Implementation of basic_symbol constructor for each type.
-
template <typename Base>
- D2Parser::basic_symbol<Base>::basic_symbol (typename Base::kind_type t, const location_type& l)
+ D2Parser::basic_symbol<Base>::basic_symbol (typename Base::kind_type t, YY_RVREF (location_type) l)
: Base (t)
- , value ()
- , location (l)
+ , location (YY_MOVE (l))
{}
template <typename Base>
- D2Parser::basic_symbol<Base>::basic_symbol (typename Base::kind_type t, const ElementPtr v, const location_type& l)
+ D2Parser::basic_symbol<Base>::basic_symbol (typename Base::kind_type t, YY_RVREF (ElementPtr) v, YY_RVREF (location_type) l)
: Base (t)
- , value (v)
- , location (l)
+ , value (YY_MOVE (v))
+ , location (YY_MOVE (l))
{}
template <typename Base>
- D2Parser::basic_symbol<Base>::basic_symbol (typename Base::kind_type t, const bool v, const location_type& l)
+ D2Parser::basic_symbol<Base>::basic_symbol (typename Base::kind_type t, YY_RVREF (bool) v, YY_RVREF (location_type) l)
: Base (t)
- , value (v)
- , location (l)
+ , value (YY_MOVE (v))
+ , location (YY_MOVE (l))
{}
template <typename Base>
- D2Parser::basic_symbol<Base>::basic_symbol (typename Base::kind_type t, const double v, const location_type& l)
+ D2Parser::basic_symbol<Base>::basic_symbol (typename Base::kind_type t, YY_RVREF (double) v, YY_RVREF (location_type) l)
: Base (t)
- , value (v)
- , location (l)
+ , value (YY_MOVE (v))
+ , location (YY_MOVE (l))
{}
template <typename Base>
- D2Parser::basic_symbol<Base>::basic_symbol (typename Base::kind_type t, const int64_t v, const location_type& l)
+ D2Parser::basic_symbol<Base>::basic_symbol (typename Base::kind_type t, YY_RVREF (int64_t) v, YY_RVREF (location_type) l)
: Base (t)
- , value (v)
- , location (l)
+ , value (YY_MOVE (v))
+ , location (YY_MOVE (l))
{}
template <typename Base>
- D2Parser::basic_symbol<Base>::basic_symbol (typename Base::kind_type t, const std::string v, const location_type& l)
+ D2Parser::basic_symbol<Base>::basic_symbol (typename Base::kind_type t, YY_RVREF (std::string) v, YY_RVREF (location_type) l)
: Base (t)
- , value (v)
- , location (l)
+ , value (YY_MOVE (v))
+ , location (YY_MOVE (l))
{}
+
template <typename Base>
D2Parser::basic_symbol<Base>::~basic_symbol ()
{
case 68: // value
case 72: // map_value
case 96: // ncr_protocol_value
- value.move< ElementPtr > (s.value);
+ value.move< ElementPtr > (YY_MOVE (s.value));
break;
case 56: // "boolean"
- value.move< bool > (s.value);
+ value.move< bool > (YY_MOVE (s.value));
break;
case 55: // "floating point"
- value.move< double > (s.value);
+ value.move< double > (YY_MOVE (s.value));
break;
case 54: // "integer"
- value.move< int64_t > (s.value);
+ value.move< int64_t > (YY_MOVE (s.value));
break;
case 53: // "constant string"
- value.move< std::string > (s.value);
+ value.move< std::string > (YY_MOVE (s.value));
break;
default:
break;
}
- location = s.location;
+ location = YY_MOVE (s.location);
}
// by_type.
// YYTOKNUM[NUM] -- (External) token number corresponding to the
// (internal) symbol number NUM (which must be that of a token). */
static
- const unsigned short int
+ const unsigned short
yytoken_number_[] =
{
0, 256, 257, 258, 259, 260, 261, 262, 263, 264,
};
return static_cast<token_type> (yytoken_number_[type]);
}
+
// Implementation of make_symbol for each symbol type.
+ inline
D2Parser::symbol_type
- D2Parser::make_END (const location_type& l)
+ D2Parser::make_END (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_END, l);
+ return symbol_type (token::TOKEN_END, YY_MOVE (l));
}
+ inline
D2Parser::symbol_type
- D2Parser::make_COMMA (const location_type& l)
+ D2Parser::make_COMMA (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_COMMA, l);
+ return symbol_type (token::TOKEN_COMMA, YY_MOVE (l));
}
+ inline
D2Parser::symbol_type
- D2Parser::make_COLON (const location_type& l)
+ D2Parser::make_COLON (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_COLON, l);
+ return symbol_type (token::TOKEN_COLON, YY_MOVE (l));
}
+ inline
D2Parser::symbol_type
- D2Parser::make_LSQUARE_BRACKET (const location_type& l)
+ D2Parser::make_LSQUARE_BRACKET (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_LSQUARE_BRACKET, l);
+ return symbol_type (token::TOKEN_LSQUARE_BRACKET, YY_MOVE (l));
}
+ inline
D2Parser::symbol_type
- D2Parser::make_RSQUARE_BRACKET (const location_type& l)
+ D2Parser::make_RSQUARE_BRACKET (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_RSQUARE_BRACKET, l);
+ return symbol_type (token::TOKEN_RSQUARE_BRACKET, YY_MOVE (l));
}
+ inline
D2Parser::symbol_type
- D2Parser::make_LCURLY_BRACKET (const location_type& l)
+ D2Parser::make_LCURLY_BRACKET (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_LCURLY_BRACKET, l);
+ return symbol_type (token::TOKEN_LCURLY_BRACKET, YY_MOVE (l));
}
+ inline
D2Parser::symbol_type
- D2Parser::make_RCURLY_BRACKET (const location_type& l)
+ D2Parser::make_RCURLY_BRACKET (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_RCURLY_BRACKET, l);
+ return symbol_type (token::TOKEN_RCURLY_BRACKET, YY_MOVE (l));
}
+ inline
D2Parser::symbol_type
- D2Parser::make_NULL_TYPE (const location_type& l)
+ D2Parser::make_NULL_TYPE (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_NULL_TYPE, l);
+ return symbol_type (token::TOKEN_NULL_TYPE, YY_MOVE (l));
}
+ inline
D2Parser::symbol_type
- D2Parser::make_DHCP6 (const location_type& l)
+ D2Parser::make_DHCP6 (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_DHCP6, l);
+ return symbol_type (token::TOKEN_DHCP6, YY_MOVE (l));
}
+ inline
D2Parser::symbol_type
- D2Parser::make_DHCP4 (const location_type& l)
+ D2Parser::make_DHCP4 (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_DHCP4, l);
+ return symbol_type (token::TOKEN_DHCP4, YY_MOVE (l));
}
+ inline
D2Parser::symbol_type
- D2Parser::make_CONTROL_AGENT (const location_type& l)
+ D2Parser::make_CONTROL_AGENT (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_CONTROL_AGENT, l);
+ return symbol_type (token::TOKEN_CONTROL_AGENT, YY_MOVE (l));
}
+ inline
D2Parser::symbol_type
- D2Parser::make_DHCPDDNS (const location_type& l)
+ D2Parser::make_DHCPDDNS (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_DHCPDDNS, l);
+ return symbol_type (token::TOKEN_DHCPDDNS, YY_MOVE (l));
}
+ inline
D2Parser::symbol_type
- D2Parser::make_IP_ADDRESS (const location_type& l)
+ D2Parser::make_IP_ADDRESS (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_IP_ADDRESS, l);
+ return symbol_type (token::TOKEN_IP_ADDRESS, YY_MOVE (l));
}
+ inline
D2Parser::symbol_type
- D2Parser::make_PORT (const location_type& l)
+ D2Parser::make_PORT (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_PORT, l);
+ return symbol_type (token::TOKEN_PORT, YY_MOVE (l));
}
+ inline
D2Parser::symbol_type
- D2Parser::make_DNS_SERVER_TIMEOUT (const location_type& l)
+ D2Parser::make_DNS_SERVER_TIMEOUT (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_DNS_SERVER_TIMEOUT, l);
+ return symbol_type (token::TOKEN_DNS_SERVER_TIMEOUT, YY_MOVE (l));
}
+ inline
D2Parser::symbol_type
- D2Parser::make_NCR_PROTOCOL (const location_type& l)
+ D2Parser::make_NCR_PROTOCOL (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_NCR_PROTOCOL, l);
+ return symbol_type (token::TOKEN_NCR_PROTOCOL, YY_MOVE (l));
}
+ inline
D2Parser::symbol_type
- D2Parser::make_UDP (const location_type& l)
+ D2Parser::make_UDP (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_UDP, l);
+ return symbol_type (token::TOKEN_UDP, YY_MOVE (l));
}
+ inline
D2Parser::symbol_type
- D2Parser::make_TCP (const location_type& l)
+ D2Parser::make_TCP (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_TCP, l);
+ return symbol_type (token::TOKEN_TCP, YY_MOVE (l));
}
+ inline
D2Parser::symbol_type
- D2Parser::make_NCR_FORMAT (const location_type& l)
+ D2Parser::make_NCR_FORMAT (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_NCR_FORMAT, l);
+ return symbol_type (token::TOKEN_NCR_FORMAT, YY_MOVE (l));
}
+ inline
D2Parser::symbol_type
- D2Parser::make_JSON (const location_type& l)
+ D2Parser::make_JSON (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_JSON, l);
+ return symbol_type (token::TOKEN_JSON, YY_MOVE (l));
}
+ inline
D2Parser::symbol_type
- D2Parser::make_USER_CONTEXT (const location_type& l)
+ D2Parser::make_USER_CONTEXT (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_USER_CONTEXT, l);
+ return symbol_type (token::TOKEN_USER_CONTEXT, YY_MOVE (l));
}
+ inline
D2Parser::symbol_type
- D2Parser::make_COMMENT (const location_type& l)
+ D2Parser::make_COMMENT (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_COMMENT, l);
+ return symbol_type (token::TOKEN_COMMENT, YY_MOVE (l));
}
+ inline
D2Parser::symbol_type
- D2Parser::make_FORWARD_DDNS (const location_type& l)
+ D2Parser::make_FORWARD_DDNS (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_FORWARD_DDNS, l);
+ return symbol_type (token::TOKEN_FORWARD_DDNS, YY_MOVE (l));
}
+ inline
D2Parser::symbol_type
- D2Parser::make_REVERSE_DDNS (const location_type& l)
+ D2Parser::make_REVERSE_DDNS (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_REVERSE_DDNS, l);
+ return symbol_type (token::TOKEN_REVERSE_DDNS, YY_MOVE (l));
}
+ inline
D2Parser::symbol_type
- D2Parser::make_DDNS_DOMAINS (const location_type& l)
+ D2Parser::make_DDNS_DOMAINS (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_DDNS_DOMAINS, l);
+ return symbol_type (token::TOKEN_DDNS_DOMAINS, YY_MOVE (l));
}
+ inline
D2Parser::symbol_type
- D2Parser::make_KEY_NAME (const location_type& l)
+ D2Parser::make_KEY_NAME (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_KEY_NAME, l);
+ return symbol_type (token::TOKEN_KEY_NAME, YY_MOVE (l));
}
+ inline
D2Parser::symbol_type
- D2Parser::make_DNS_SERVERS (const location_type& l)
+ D2Parser::make_DNS_SERVERS (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_DNS_SERVERS, l);
+ return symbol_type (token::TOKEN_DNS_SERVERS, YY_MOVE (l));
}
+ inline
D2Parser::symbol_type
- D2Parser::make_HOSTNAME (const location_type& l)
+ D2Parser::make_HOSTNAME (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_HOSTNAME, l);
+ return symbol_type (token::TOKEN_HOSTNAME, YY_MOVE (l));
}
+ inline
D2Parser::symbol_type
- D2Parser::make_TSIG_KEYS (const location_type& l)
+ D2Parser::make_TSIG_KEYS (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_TSIG_KEYS, l);
+ return symbol_type (token::TOKEN_TSIG_KEYS, YY_MOVE (l));
}
+ inline
D2Parser::symbol_type
- D2Parser::make_ALGORITHM (const location_type& l)
+ D2Parser::make_ALGORITHM (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_ALGORITHM, l);
+ return symbol_type (token::TOKEN_ALGORITHM, YY_MOVE (l));
}
+ inline
D2Parser::symbol_type
- D2Parser::make_DIGEST_BITS (const location_type& l)
+ D2Parser::make_DIGEST_BITS (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_DIGEST_BITS, l);
+ return symbol_type (token::TOKEN_DIGEST_BITS, YY_MOVE (l));
}
+ inline
D2Parser::symbol_type
- D2Parser::make_SECRET (const location_type& l)
+ D2Parser::make_SECRET (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_SECRET, l);
+ return symbol_type (token::TOKEN_SECRET, YY_MOVE (l));
}
+ inline
D2Parser::symbol_type
- D2Parser::make_LOGGING (const location_type& l)
+ D2Parser::make_LOGGING (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_LOGGING, l);
+ return symbol_type (token::TOKEN_LOGGING, YY_MOVE (l));
}
+ inline
D2Parser::symbol_type
- D2Parser::make_LOGGERS (const location_type& l)
+ D2Parser::make_LOGGERS (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_LOGGERS, l);
+ return symbol_type (token::TOKEN_LOGGERS, YY_MOVE (l));
}
+ inline
D2Parser::symbol_type
- D2Parser::make_NAME (const location_type& l)
+ D2Parser::make_NAME (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_NAME, l);
+ return symbol_type (token::TOKEN_NAME, YY_MOVE (l));
}
+ inline
D2Parser::symbol_type
- D2Parser::make_OUTPUT_OPTIONS (const location_type& l)
+ D2Parser::make_OUTPUT_OPTIONS (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_OUTPUT_OPTIONS, l);
+ return symbol_type (token::TOKEN_OUTPUT_OPTIONS, YY_MOVE (l));
}
+ inline
D2Parser::symbol_type
- D2Parser::make_OUTPUT (const location_type& l)
+ D2Parser::make_OUTPUT (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_OUTPUT, l);
+ return symbol_type (token::TOKEN_OUTPUT, YY_MOVE (l));
}
+ inline
D2Parser::symbol_type
- D2Parser::make_DEBUGLEVEL (const location_type& l)
+ D2Parser::make_DEBUGLEVEL (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_DEBUGLEVEL, l);
+ return symbol_type (token::TOKEN_DEBUGLEVEL, YY_MOVE (l));
}
+ inline
D2Parser::symbol_type
- D2Parser::make_SEVERITY (const location_type& l)
+ D2Parser::make_SEVERITY (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_SEVERITY, l);
+ return symbol_type (token::TOKEN_SEVERITY, YY_MOVE (l));
}
+ inline
D2Parser::symbol_type
- D2Parser::make_FLUSH (const location_type& l)
+ D2Parser::make_FLUSH (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_FLUSH, l);
+ return symbol_type (token::TOKEN_FLUSH, YY_MOVE (l));
}
+ inline
D2Parser::symbol_type
- D2Parser::make_MAXSIZE (const location_type& l)
+ D2Parser::make_MAXSIZE (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_MAXSIZE, l);
+ return symbol_type (token::TOKEN_MAXSIZE, YY_MOVE (l));
}
+ inline
D2Parser::symbol_type
- D2Parser::make_MAXVER (const location_type& l)
+ D2Parser::make_MAXVER (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_MAXVER, l);
+ return symbol_type (token::TOKEN_MAXVER, YY_MOVE (l));
}
+ inline
D2Parser::symbol_type
- D2Parser::make_TOPLEVEL_JSON (const location_type& l)
+ D2Parser::make_TOPLEVEL_JSON (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_TOPLEVEL_JSON, l);
+ return symbol_type (token::TOKEN_TOPLEVEL_JSON, YY_MOVE (l));
}
+ inline
D2Parser::symbol_type
- D2Parser::make_TOPLEVEL_DHCPDDNS (const location_type& l)
+ D2Parser::make_TOPLEVEL_DHCPDDNS (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_TOPLEVEL_DHCPDDNS, l);
+ return symbol_type (token::TOKEN_TOPLEVEL_DHCPDDNS, YY_MOVE (l));
}
+ inline
D2Parser::symbol_type
- D2Parser::make_SUB_DHCPDDNS (const location_type& l)
+ D2Parser::make_SUB_DHCPDDNS (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_SUB_DHCPDDNS, l);
+ return symbol_type (token::TOKEN_SUB_DHCPDDNS, YY_MOVE (l));
}
+ inline
D2Parser::symbol_type
- D2Parser::make_SUB_TSIG_KEY (const location_type& l)
+ D2Parser::make_SUB_TSIG_KEY (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_SUB_TSIG_KEY, l);
+ return symbol_type (token::TOKEN_SUB_TSIG_KEY, YY_MOVE (l));
}
+ inline
D2Parser::symbol_type
- D2Parser::make_SUB_TSIG_KEYS (const location_type& l)
+ D2Parser::make_SUB_TSIG_KEYS (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_SUB_TSIG_KEYS, l);
+ return symbol_type (token::TOKEN_SUB_TSIG_KEYS, YY_MOVE (l));
}
+ inline
D2Parser::symbol_type
- D2Parser::make_SUB_DDNS_DOMAIN (const location_type& l)
+ D2Parser::make_SUB_DDNS_DOMAIN (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_SUB_DDNS_DOMAIN, l);
+ return symbol_type (token::TOKEN_SUB_DDNS_DOMAIN, YY_MOVE (l));
}
+ inline
D2Parser::symbol_type
- D2Parser::make_SUB_DDNS_DOMAINS (const location_type& l)
+ D2Parser::make_SUB_DDNS_DOMAINS (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_SUB_DDNS_DOMAINS, l);
+ return symbol_type (token::TOKEN_SUB_DDNS_DOMAINS, YY_MOVE (l));
}
+ inline
D2Parser::symbol_type
- D2Parser::make_SUB_DNS_SERVER (const location_type& l)
+ D2Parser::make_SUB_DNS_SERVER (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_SUB_DNS_SERVER, l);
+ return symbol_type (token::TOKEN_SUB_DNS_SERVER, YY_MOVE (l));
}
+ inline
D2Parser::symbol_type
- D2Parser::make_SUB_DNS_SERVERS (const location_type& l)
+ D2Parser::make_SUB_DNS_SERVERS (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_SUB_DNS_SERVERS, l);
+ return symbol_type (token::TOKEN_SUB_DNS_SERVERS, YY_MOVE (l));
}
+ inline
D2Parser::symbol_type
- D2Parser::make_STRING (const std::string& v, const location_type& l)
+ D2Parser::make_STRING (YY_COPY (std::string) v, YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_STRING, v, l);
+ return symbol_type (token::TOKEN_STRING, YY_MOVE (v), YY_MOVE (l));
}
+ inline
D2Parser::symbol_type
- D2Parser::make_INTEGER (const int64_t& v, const location_type& l)
+ D2Parser::make_INTEGER (YY_COPY (int64_t) v, YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_INTEGER, v, l);
+ return symbol_type (token::TOKEN_INTEGER, YY_MOVE (v), YY_MOVE (l));
}
+ inline
D2Parser::symbol_type
- D2Parser::make_FLOAT (const double& v, const location_type& l)
+ D2Parser::make_FLOAT (YY_COPY (double) v, YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_FLOAT, v, l);
+ return symbol_type (token::TOKEN_FLOAT, YY_MOVE (v), YY_MOVE (l));
}
+ inline
D2Parser::symbol_type
- D2Parser::make_BOOLEAN (const bool& v, const location_type& l)
+ D2Parser::make_BOOLEAN (YY_COPY (bool) v, YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_BOOLEAN, v, l);
+ return symbol_type (token::TOKEN_BOOLEAN, YY_MOVE (v), YY_MOVE (l));
}
-#line 14 "d2_parser.yy" // lalr1.cc:379
+#line 14 "d2_parser.yy" // lalr1.cc:404
} } // isc::d2
-#line 1624 "d2_parser.h" // lalr1.cc:379
+#line 1834 "d2_parser.h" // lalr1.cc:404
-// Generated 201811151407
-// A Bison parser, made by GNU Bison 3.0.5.
+// Generated 201811172153
+// A Bison parser, made by GNU Bison 3.2.1.
// Locations for Bison parsers in C++
#ifndef YY_D2_PARSER_LOCATION_HH_INCLUDED
# define YY_D2_PARSER_LOCATION_HH_INCLUDED
-# include "position.hh"
+# include <algorithm> // std::max
+# include <iostream>
+# include <string>
-#line 14 "d2_parser.yy" // location.cc:292
+# ifndef YY_NULLPTR
+# if defined __cplusplus
+# if 201103L <= __cplusplus
+# define YY_NULLPTR nullptr
+# else
+# define YY_NULLPTR 0
+# endif
+# else
+# define YY_NULLPTR ((void*)0)
+# endif
+# endif
+
+#line 14 "d2_parser.yy" // location.cc:339
namespace isc { namespace d2 {
-#line 46 "location.hh" // location.cc:292
- /// Abstract a location.
+#line 60 "location.hh" // location.cc:339
+ /// A point in a source file.
+ class position
+ {
+ public:
+ /// Construct a position.
+ explicit position (std::string* f = YY_NULLPTR,
+ unsigned l = 1u,
+ unsigned c = 1u)
+ : filename (f)
+ , line (l)
+ , column (c)
+ {}
+
+
+ /// Initialization.
+ void initialize (std::string* fn = YY_NULLPTR,
+ unsigned l = 1u,
+ unsigned c = 1u)
+ {
+ filename = fn;
+ line = l;
+ column = c;
+ }
+
+ /** \name Line and Column related manipulators
+ ** \{ */
+ /// (line related) Advance to the COUNT next lines.
+ void lines (int count = 1)
+ {
+ if (count)
+ {
+ column = 1u;
+ line = add_ (line, count, 1);
+ }
+ }
+
+ /// (column related) Advance to the COUNT next columns.
+ void columns (int count = 1)
+ {
+ column = add_ (column, count, 1);
+ }
+ /** \} */
+
+ /// File name to which this position refers.
+ std::string* filename;
+ /// Current line number.
+ unsigned line;
+ /// Current column number.
+ unsigned column;
+
+ private:
+ /// Compute max (min, lhs+rhs).
+ static unsigned add_ (unsigned lhs, int rhs, int min)
+ {
+ return static_cast<unsigned> (std::max (min,
+ static_cast<int> (lhs) + rhs));
+ }
+ };
+
+ /// Add \a width columns, in place.
+ inline position&
+ operator+= (position& res, int width)
+ {
+ res.columns (width);
+ return res;
+ }
+
+ /// Add \a width columns.
+ inline position
+ operator+ (position res, int width)
+ {
+ return res += width;
+ }
+
+ /// Subtract \a width columns, in place.
+ inline position&
+ operator-= (position& res, int width)
+ {
+ return res += -width;
+ }
+
+ /// Subtract \a width columns.
+ inline position
+ operator- (position res, int width)
+ {
+ return res -= width;
+ }
+
+ /// Compare two position objects.
+ inline bool
+ operator== (const position& pos1, const position& pos2)
+ {
+ return (pos1.line == pos2.line
+ && pos1.column == pos2.column
+ && (pos1.filename == pos2.filename
+ || (pos1.filename && pos2.filename
+ && *pos1.filename == *pos2.filename)));
+ }
+
+ /// Compare two position objects.
+ inline bool
+ operator!= (const position& pos1, const position& pos2)
+ {
+ return !(pos1 == pos2);
+ }
+
+ /** \brief Intercept output stream redirection.
+ ** \param ostr the destination output stream
+ ** \param pos a reference to the position to redirect
+ */
+ template <typename YYChar>
+ std::basic_ostream<YYChar>&
+ operator<< (std::basic_ostream<YYChar>& ostr, const position& pos)
+ {
+ if (pos.filename)
+ ostr << *pos.filename << ':';
+ return ostr << pos.line << '.' << pos.column;
+ }
+
+ /// Two points in a source file.
class location
{
public:
** Avoid duplicate information.
*/
template <typename YYChar>
- inline std::basic_ostream<YYChar>&
+ std::basic_ostream<YYChar>&
operator<< (std::basic_ostream<YYChar>& ostr, const location& loc)
{
unsigned end_col = 0 < loc.end.column ? loc.end.column - 1 : 0;
return ostr;
}
-#line 14 "d2_parser.yy" // location.cc:292
+#line 14 "d2_parser.yy" // location.cc:339
} } // isc::d2
-#line 189 "location.hh" // location.cc:292
+#line 322 "location.hh" // location.cc:339
#endif // !YY_D2_PARSER_LOCATION_HH_INCLUDED
-// Generated 201811151407
-// A Bison parser, made by GNU Bison 3.0.5.
-
-// Positions for Bison parsers in C++
-
-// Copyright (C) 2002-2015, 2018 Free Software Foundation, Inc.
-
-// This program is free software: you can redistribute it and/or modify
-// it under the terms of the GNU General Public License as published by
-// the Free Software Foundation, either version 3 of the License, or
-// (at your option) any later version.
-
-// This program is distributed in the hope that it will be useful,
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-// GNU General Public License for more details.
-
-// You should have received a copy of the GNU General Public License
-// along with this program. If not, see <http://www.gnu.org/licenses/>.
-
-// As a special exception, you may create a larger work that contains
-// part or all of the Bison parser skeleton and distribute that work
-// under terms of your choice, so long as that work isn't itself a
-// parser generator using the skeleton or a modified version thereof
-// as a parser skeleton. Alternatively, if you modify or redistribute
-// the parser skeleton itself, you may (at your option) remove this
-// special exception, which will cause the skeleton and the resulting
-// Bison output files to be licensed under the GNU General Public
-// License without this special exception.
-
-// This special exception was added by the Free Software Foundation in
-// version 2.2 of Bison.
-
-/**
- ** \file position.hh
- ** Define the isc::d2::position class.
- */
-
-#ifndef YY_D2_PARSER_POSITION_HH_INCLUDED
-# define YY_D2_PARSER_POSITION_HH_INCLUDED
-
-# include <algorithm> // std::max
-# include <iostream>
-# include <string>
-
-# ifndef YY_NULLPTR
-# if defined __cplusplus && 201103L <= __cplusplus
-# define YY_NULLPTR nullptr
-# else
-# define YY_NULLPTR 0
-# endif
-# endif
-
-#line 14 "d2_parser.yy" // location.cc:292
-namespace isc { namespace d2 {
-#line 56 "position.hh" // location.cc:292
- /// Abstract a position.
- class position
- {
- public:
- /// Construct a position.
- explicit position (std::string* f = YY_NULLPTR,
- unsigned l = 1u,
- unsigned c = 1u)
- : filename (f)
- , line (l)
- , column (c)
- {}
-
-
- /// Initialization.
- void initialize (std::string* fn = YY_NULLPTR,
- unsigned l = 1u,
- unsigned c = 1u)
- {
- filename = fn;
- line = l;
- column = c;
- }
-
- /** \name Line and Column related manipulators
- ** \{ */
- /// (line related) Advance to the COUNT next lines.
- void lines (int count = 1)
- {
- if (count)
- {
- column = 1u;
- line = add_ (line, count, 1);
- }
- }
-
- /// (column related) Advance to the COUNT next columns.
- void columns (int count = 1)
- {
- column = add_ (column, count, 1);
- }
- /** \} */
-
- /// File name to which this position refers.
- std::string* filename;
- /// Current line number.
- unsigned line;
- /// Current column number.
- unsigned column;
-
- private:
- /// Compute max(min, lhs+rhs) (provided min <= lhs).
- static unsigned add_ (unsigned lhs, int rhs, unsigned min)
- {
- return (0 < rhs || -static_cast<unsigned>(rhs) < lhs
- ? rhs + lhs
- : min);
- }
- };
-
- /// Add \a width columns, in place.
- inline position&
- operator+= (position& res, int width)
- {
- res.columns (width);
- return res;
- }
-
- /// Add \a width columns.
- inline position
- operator+ (position res, int width)
- {
- return res += width;
- }
-
- /// Subtract \a width columns, in place.
- inline position&
- operator-= (position& res, int width)
- {
- return res += -width;
- }
-
- /// Subtract \a width columns.
- inline position
- operator- (position res, int width)
- {
- return res -= width;
- }
-
- /// Compare two position objects.
- inline bool
- operator== (const position& pos1, const position& pos2)
- {
- return (pos1.line == pos2.line
- && pos1.column == pos2.column
- && (pos1.filename == pos2.filename
- || (pos1.filename && pos2.filename
- && *pos1.filename == *pos2.filename)));
- }
-
- /// Compare two position objects.
- inline bool
- operator!= (const position& pos1, const position& pos2)
- {
- return !(pos1 == pos2);
- }
-
- /** \brief Intercept output stream redirection.
- ** \param ostr the destination output stream
- ** \param pos a reference to the position to redirect
- */
- template <typename YYChar>
- inline std::basic_ostream<YYChar>&
- operator<< (std::basic_ostream<YYChar>& ostr, const position& pos)
- {
- if (pos.filename)
- ostr << *pos.filename << ':';
- return ostr << pos.line << '.' << pos.column;
- }
-
-#line 14 "d2_parser.yy" // location.cc:292
-} } // isc::d2
-#line 179 "position.hh" // location.cc:292
-#endif // !YY_D2_PARSER_POSITION_HH_INCLUDED
+// Generated 201811172153
+// A Bison parser, made by GNU Bison 3.2.1.
+
+// Starting with Bison 3.2, this file is useless: the structure it
+// used to define is now defined in "location.hh".
+//
+// To get rid of this file:
+// 1. add 'require "3.2"' (or newer) to your grammar file
+// 2. remove references to this file from your build system
+// 3. if you used to include it, include "location.hh" instead.
+
+#include "location.hh"
-// Generated 201811151407
-// A Bison parser, made by GNU Bison 3.0.5.
-
-// Stack handling for Bison parsers in C++
-
-// Copyright (C) 2002-2015, 2018 Free Software Foundation, Inc.
-
-// This program is free software: you can redistribute it and/or modify
-// it under the terms of the GNU General Public License as published by
-// the Free Software Foundation, either version 3 of the License, or
-// (at your option) any later version.
-
-// This program is distributed in the hope that it will be useful,
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-// GNU General Public License for more details.
-
-// You should have received a copy of the GNU General Public License
-// along with this program. If not, see <http://www.gnu.org/licenses/>.
-
-// As a special exception, you may create a larger work that contains
-// part or all of the Bison parser skeleton and distribute that work
-// under terms of your choice, so long as that work isn't itself a
-// parser generator using the skeleton or a modified version thereof
-// as a parser skeleton. Alternatively, if you modify or redistribute
-// the parser skeleton itself, you may (at your option) remove this
-// special exception, which will cause the skeleton and the resulting
-// Bison output files to be licensed under the GNU General Public
-// License without this special exception.
-
-// This special exception was added by the Free Software Foundation in
-// version 2.2 of Bison.
-
-/**
- ** \file stack.hh
- ** Define the isc::d2::stack class.
- */
-
-#ifndef YY_D2_PARSER_STACK_HH_INCLUDED
-# define YY_D2_PARSER_STACK_HH_INCLUDED
-
-# include <vector>
-
-#line 14 "d2_parser.yy" // stack.hh:131
-namespace isc { namespace d2 {
-#line 46 "stack.hh" // stack.hh:131
- /// A stack with random access from its top.
- template <class T, class S = std::vector<T> >
- class stack
- {
- public:
- // Hide our reversed order.
- typedef typename S::reverse_iterator iterator;
- typedef typename S::const_reverse_iterator const_iterator;
-
- stack ()
- : seq_ ()
- {
- seq_.reserve (200);
- }
-
- stack (unsigned n)
- : seq_ (n)
- {}
-
- /// Random access.
- ///
- /// Index 0 returns the topmost element.
- T&
- operator[] (unsigned i)
- {
- return seq_[seq_.size () - 1 - i];
- }
-
- /// Random access.
- ///
- /// Index 0 returns the topmost element.
- const T&
- operator[] (unsigned i) const
- {
- return seq_[seq_.size () - 1 - i];
- }
-
- /// Steal the contents of \a t.
- ///
- /// Close to move-semantics.
- void
- push (T& t)
- {
- seq_.push_back (T());
- operator[](0).move (t);
- }
-
- void
- pop (unsigned n = 1)
- {
- for (; n; --n)
- seq_.pop_back ();
- }
-
- void
- clear ()
- {
- seq_.clear ();
- }
-
- typename S::size_type
- size () const
- {
- return seq_.size ();
- }
-
- const_iterator
- begin () const
- {
- return seq_.rbegin ();
- }
-
- const_iterator
- end () const
- {
- return seq_.rend ();
- }
-
- private:
- stack (const stack&);
- stack& operator= (const stack&);
- /// The wrapped container.
- S seq_;
- };
-
- /// Present a slice of the top of a stack.
- template <class T, class S = stack<T> >
- class slice
- {
- public:
- slice (const S& stack, unsigned range)
- : stack_ (stack)
- , range_ (range)
- {}
-
- const T&
- operator [] (unsigned i) const
- {
- return stack_[range_ - i];
- }
-
- private:
- const S& stack_;
- unsigned range_;
- };
-
-#line 14 "d2_parser.yy" // stack.hh:131
-} } // isc::d2
-#line 155 "stack.hh" // stack.hh:131
-
-#endif // !YY_D2_PARSER_STACK_HH_INCLUDED
+// Generated 201811172153
+// A Bison parser, made by GNU Bison 3.2.1.
+
+// Starting with Bison 3.2, this file is useless: the structure it
+// used to define is now defined with the parser itself.
+//
+// To get rid of this file:
+// 1. add 'require "3.2"' (or newer) to your grammar file
+// 2. remove references to this file from your build system.
-// A Bison parser, made by GNU Bison 3.0.5.
+// A Bison parser, made by GNU Bison 3.2.1.
// Skeleton implementation for Bison LALR(1) parsers in C++
// This special exception was added by the Free Software Foundation in
// version 2.2 of Bison.
+// Undocumented macros, especially those whose name start with YY_,
+// are private implementation details. Do not rely on them.
+
+
// Take the name prefix into account.
#define yylex parser4_lex
-// First part of user declarations.
-#line 39 "dhcp4_parser.cc" // lalr1.cc:406
-
-# ifndef YY_NULLPTR
-# if defined __cplusplus && 201103L <= __cplusplus
-# define YY_NULLPTR nullptr
-# else
-# define YY_NULLPTR 0
-# endif
-# endif
#include "dhcp4_parser.h"
-// User implementation prologue.
-#line 53 "dhcp4_parser.cc" // lalr1.cc:414
// Unqualified %code blocks.
-#line 34 "dhcp4_parser.yy" // lalr1.cc:415
+#line 34 "dhcp4_parser.yy" // lalr1.cc:438
#include <dhcp4/parser_context.h>
-#line 59 "dhcp4_parser.cc" // lalr1.cc:415
+#line 51 "dhcp4_parser.cc" // lalr1.cc:438
#ifndef YY_
# endif
#endif
+// Whether we are compiled with exception support.
+#ifndef YY_EXCEPTIONS
+# if defined __GNUC__ && !defined __EXCEPTIONS
+# define YY_EXCEPTIONS 0
+# else
+# define YY_EXCEPTIONS 1
+# endif
+#endif
+
#define YYRHSLOC(Rhs, K) ((Rhs)[K].location)
/* YYLLOC_DEFAULT -- Set CURRENT to span from RHS[1] to RHS[N].
If N is 0, then set CURRENT to the empty location which ends
#define YYERROR goto yyerrorlab
#define YYRECOVERING() (!!yyerrstatus_)
-#line 14 "dhcp4_parser.yy" // lalr1.cc:481
+#line 14 "dhcp4_parser.yy" // lalr1.cc:513
namespace isc { namespace dhcp {
-#line 145 "dhcp4_parser.cc" // lalr1.cc:481
+#line 146 "dhcp4_parser.cc" // lalr1.cc:513
/* Return YYSTR after stripping away unnecessary quotes and
backslashes, so that it's suitable for yyerror. The heuristic is
Dhcp4Parser::stack_symbol_type::stack_symbol_type ()
{}
- Dhcp4Parser::stack_symbol_type::stack_symbol_type (const stack_symbol_type& that)
- : super_type (that.state, that.location)
+ Dhcp4Parser::stack_symbol_type::stack_symbol_type (YY_RVREF (stack_symbol_type) that)
+ : super_type (YY_MOVE (that.state), YY_MOVE (that.location))
{
switch (that.type_get ())
{
case 338: // hr_mode
case 487: // ncr_protocol_value
case 495: // replace_client_name_value
- value.copy< ElementPtr > (that.value);
+ value.YY_MOVE_OR_COPY< ElementPtr > (YY_MOVE (that.value));
break;
case 169: // "boolean"
- value.copy< bool > (that.value);
+ value.YY_MOVE_OR_COPY< bool > (YY_MOVE (that.value));
break;
case 168: // "floating point"
- value.copy< double > (that.value);
+ value.YY_MOVE_OR_COPY< double > (YY_MOVE (that.value));
break;
case 167: // "integer"
- value.copy< int64_t > (that.value);
+ value.YY_MOVE_OR_COPY< int64_t > (YY_MOVE (that.value));
break;
case 166: // "constant string"
- value.copy< std::string > (that.value);
+ value.YY_MOVE_OR_COPY< std::string > (YY_MOVE (that.value));
break;
default:
break;
}
+#if defined __cplusplus && 201103L <= __cplusplus
+ // that is emptied.
+ that.state = empty_state;
+#endif
}
- Dhcp4Parser::stack_symbol_type::stack_symbol_type (state_type s, symbol_type& that)
- : super_type (s, that.location)
+ Dhcp4Parser::stack_symbol_type::stack_symbol_type (state_type s, YY_MOVE_REF (symbol_type) that)
+ : super_type (s, YY_MOVE (that.location))
{
switch (that.type_get ())
{
case 338: // hr_mode
case 487: // ncr_protocol_value
case 495: // replace_client_name_value
- value.move< ElementPtr > (that.value);
+ value.move< ElementPtr > (YY_MOVE (that.value));
break;
case 169: // "boolean"
- value.move< bool > (that.value);
+ value.move< bool > (YY_MOVE (that.value));
break;
case 168: // "floating point"
- value.move< double > (that.value);
+ value.move< double > (YY_MOVE (that.value));
break;
case 167: // "integer"
- value.move< int64_t > (that.value);
+ value.move< int64_t > (YY_MOVE (that.value));
break;
case 166: // "constant string"
- value.move< std::string > (that.value);
+ value.move< std::string > (YY_MOVE (that.value));
break;
default:
that.type = empty_symbol;
}
+#if !defined __cplusplus || __cplusplus < 201103L
Dhcp4Parser::stack_symbol_type&
- Dhcp4Parser::stack_symbol_type::operator= (const stack_symbol_type& that)
+ Dhcp4Parser::stack_symbol_type::operator= (stack_symbol_type& that)
{
state = that.state;
switch (that.type_get ())
case 338: // hr_mode
case 487: // ncr_protocol_value
case 495: // replace_client_name_value
- value.copy< ElementPtr > (that.value);
+ value.move< ElementPtr > (that.value);
break;
case 169: // "boolean"
- value.copy< bool > (that.value);
+ value.move< bool > (that.value);
break;
case 168: // "floating point"
- value.copy< double > (that.value);
+ value.move< double > (that.value);
break;
case 167: // "integer"
- value.copy< int64_t > (that.value);
+ value.move< int64_t > (that.value);
break;
case 166: // "constant string"
- value.copy< std::string > (that.value);
+ value.move< std::string > (that.value);
break;
default:
}
location = that.location;
+ // that is emptied.
+ that.state = empty_state;
return *this;
}
-
+#endif
template <typename Base>
void
{
case 166: // "constant string"
-#line 246 "dhcp4_parser.yy" // lalr1.cc:635
+#line 246 "dhcp4_parser.yy" // lalr1.cc:672
{ yyoutput << yysym.value.template as< std::string > (); }
-#line 393 "dhcp4_parser.cc" // lalr1.cc:635
+#line 401 "dhcp4_parser.cc" // lalr1.cc:672
break;
case 167: // "integer"
-#line 246 "dhcp4_parser.yy" // lalr1.cc:635
+#line 246 "dhcp4_parser.yy" // lalr1.cc:672
{ yyoutput << yysym.value.template as< int64_t > (); }
-#line 400 "dhcp4_parser.cc" // lalr1.cc:635
+#line 408 "dhcp4_parser.cc" // lalr1.cc:672
break;
case 168: // "floating point"
-#line 246 "dhcp4_parser.yy" // lalr1.cc:635
+#line 246 "dhcp4_parser.yy" // lalr1.cc:672
{ yyoutput << yysym.value.template as< double > (); }
-#line 407 "dhcp4_parser.cc" // lalr1.cc:635
+#line 415 "dhcp4_parser.cc" // lalr1.cc:672
break;
case 169: // "boolean"
-#line 246 "dhcp4_parser.yy" // lalr1.cc:635
+#line 246 "dhcp4_parser.yy" // lalr1.cc:672
{ yyoutput << yysym.value.template as< bool > (); }
-#line 414 "dhcp4_parser.cc" // lalr1.cc:635
+#line 422 "dhcp4_parser.cc" // lalr1.cc:672
break;
case 186: // value
-#line 246 "dhcp4_parser.yy" // lalr1.cc:635
+#line 246 "dhcp4_parser.yy" // lalr1.cc:672
{ yyoutput << yysym.value.template as< ElementPtr > (); }
-#line 421 "dhcp4_parser.cc" // lalr1.cc:635
+#line 429 "dhcp4_parser.cc" // lalr1.cc:672
break;
case 190: // map_value
-#line 246 "dhcp4_parser.yy" // lalr1.cc:635
+#line 246 "dhcp4_parser.yy" // lalr1.cc:672
{ yyoutput << yysym.value.template as< ElementPtr > (); }
-#line 428 "dhcp4_parser.cc" // lalr1.cc:635
+#line 436 "dhcp4_parser.cc" // lalr1.cc:672
break;
case 231: // socket_type
-#line 246 "dhcp4_parser.yy" // lalr1.cc:635
+#line 246 "dhcp4_parser.yy" // lalr1.cc:672
{ yyoutput << yysym.value.template as< ElementPtr > (); }
-#line 435 "dhcp4_parser.cc" // lalr1.cc:635
+#line 443 "dhcp4_parser.cc" // lalr1.cc:672
break;
case 234: // outbound_interface_value
-#line 246 "dhcp4_parser.yy" // lalr1.cc:635
+#line 246 "dhcp4_parser.yy" // lalr1.cc:672
{ yyoutput << yysym.value.template as< ElementPtr > (); }
-#line 442 "dhcp4_parser.cc" // lalr1.cc:635
+#line 450 "dhcp4_parser.cc" // lalr1.cc:672
break;
case 256: // db_type
-#line 246 "dhcp4_parser.yy" // lalr1.cc:635
+#line 246 "dhcp4_parser.yy" // lalr1.cc:672
{ yyoutput << yysym.value.template as< ElementPtr > (); }
-#line 449 "dhcp4_parser.cc" // lalr1.cc:635
+#line 457 "dhcp4_parser.cc" // lalr1.cc:672
break;
case 338: // hr_mode
-#line 246 "dhcp4_parser.yy" // lalr1.cc:635
+#line 246 "dhcp4_parser.yy" // lalr1.cc:672
{ yyoutput << yysym.value.template as< ElementPtr > (); }
-#line 456 "dhcp4_parser.cc" // lalr1.cc:635
+#line 464 "dhcp4_parser.cc" // lalr1.cc:672
break;
case 487: // ncr_protocol_value
-#line 246 "dhcp4_parser.yy" // lalr1.cc:635
+#line 246 "dhcp4_parser.yy" // lalr1.cc:672
{ yyoutput << yysym.value.template as< ElementPtr > (); }
-#line 463 "dhcp4_parser.cc" // lalr1.cc:635
+#line 471 "dhcp4_parser.cc" // lalr1.cc:672
break;
case 495: // replace_client_name_value
-#line 246 "dhcp4_parser.yy" // lalr1.cc:635
+#line 246 "dhcp4_parser.yy" // lalr1.cc:672
{ yyoutput << yysym.value.template as< ElementPtr > (); }
-#line 470 "dhcp4_parser.cc" // lalr1.cc:635
+#line 478 "dhcp4_parser.cc" // lalr1.cc:672
break;
#endif
void
- Dhcp4Parser::yypush_ (const char* m, state_type s, symbol_type& sym)
+ Dhcp4Parser::yypush_ (const char* m, YY_MOVE_REF (stack_symbol_type) sym)
{
- stack_symbol_type t (s, sym);
- yypush_ (m, t);
+ if (m)
+ YY_SYMBOL_PRINT (m, sym);
+ yystack_.push (YY_MOVE (sym));
}
void
- Dhcp4Parser::yypush_ (const char* m, stack_symbol_type& s)
+ Dhcp4Parser::yypush_ (const char* m, state_type s, YY_MOVE_REF (symbol_type) sym)
{
- if (m)
- YY_SYMBOL_PRINT (m, s);
- yystack_.push (s);
+#if defined __cplusplus && 201103L <= __cplusplus
+ yypush_ (m, stack_symbol_type (s, std::move (sym)));
+#else
+ stack_symbol_type ss (s, sym);
+ yypush_ (m, ss);
+#endif
}
void
- Dhcp4Parser::yypop_ (unsigned n)
+ Dhcp4Parser::yypop_ (int n)
{
yystack_.pop (n);
}
return yyvalue == yytable_ninf_;
}
+ int
+ Dhcp4Parser::operator() ()
+ {
+ return parse ();
+ }
+
int
Dhcp4Parser::parse ()
{
/// The return value of parse ().
int yyresult;
- // FIXME: This shoud be completely indented. It is not yet to
- // avoid gratuitous conflicts when merging into the master branch.
+#if YY_EXCEPTIONS
try
+#endif // YY_EXCEPTIONS
{
YYCDEBUG << "Starting parse\n";
location values to have been already stored, initialize these
stacks with a primary value. */
yystack_.clear ();
- yypush_ (YY_NULLPTR, 0, yyla);
+ yypush_ (YY_NULLPTR, 0, YY_MOVE (yyla));
// A new symbol was pushed on the stack.
yynewstate:
// Backup.
yybackup:
-
// Try to take a decision without lookahead.
yyn = yypact_[yystack_[0].state];
if (yy_pact_value_is_default_ (yyn))
if (yyla.empty ())
{
YYCDEBUG << "Reading a token: ";
+#if YY_EXCEPTIONS
try
+#endif // YY_EXCEPTIONS
{
symbol_type yylookahead (yylex (ctx));
yyla.move (yylookahead);
}
+#if YY_EXCEPTIONS
catch (const syntax_error& yyexc)
{
error (yyexc);
goto yyerrlab1;
}
+#endif // YY_EXCEPTIONS
}
YY_SYMBOL_PRINT ("Next token is", yyla);
--yyerrstatus_;
// Shift the lookahead token.
- yypush_ ("Shifting", yyn, yyla);
+ yypush_ ("Shifting", yyn, YY_MOVE (yyla));
goto yynewstate;
/*-----------------------------------------------------------.
case 338: // hr_mode
case 487: // ncr_protocol_value
case 495: // replace_client_name_value
- yylhs.value.build< ElementPtr > ();
+ yylhs.value.emplace< ElementPtr > ();
break;
case 169: // "boolean"
- yylhs.value.build< bool > ();
+ yylhs.value.emplace< bool > ();
break;
case 168: // "floating point"
- yylhs.value.build< double > ();
+ yylhs.value.emplace< double > ();
break;
case 167: // "integer"
- yylhs.value.build< int64_t > ();
+ yylhs.value.emplace< int64_t > ();
break;
case 166: // "constant string"
- yylhs.value.build< std::string > ();
+ yylhs.value.emplace< std::string > ();
break;
default:
// Perform the reduction.
YY_REDUCE_PRINT (yyn);
+#if YY_EXCEPTIONS
try
+#endif // YY_EXCEPTIONS
{
switch (yyn)
{
case 2:
-#line 255 "dhcp4_parser.yy" // lalr1.cc:856
+#line 255 "dhcp4_parser.yy" // lalr1.cc:907
{ ctx.ctx_ = ctx.NO_KEYWORD; }
-#line 715 "dhcp4_parser.cc" // lalr1.cc:856
+#line 738 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 4:
-#line 256 "dhcp4_parser.yy" // lalr1.cc:856
+#line 256 "dhcp4_parser.yy" // lalr1.cc:907
{ ctx.ctx_ = ctx.CONFIG; }
-#line 721 "dhcp4_parser.cc" // lalr1.cc:856
+#line 744 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 6:
-#line 257 "dhcp4_parser.yy" // lalr1.cc:856
+#line 257 "dhcp4_parser.yy" // lalr1.cc:907
{ ctx.ctx_ = ctx.DHCP4; }
-#line 727 "dhcp4_parser.cc" // lalr1.cc:856
+#line 750 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 8:
-#line 258 "dhcp4_parser.yy" // lalr1.cc:856
+#line 258 "dhcp4_parser.yy" // lalr1.cc:907
{ ctx.ctx_ = ctx.INTERFACES_CONFIG; }
-#line 733 "dhcp4_parser.cc" // lalr1.cc:856
+#line 756 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 10:
-#line 259 "dhcp4_parser.yy" // lalr1.cc:856
+#line 259 "dhcp4_parser.yy" // lalr1.cc:907
{ ctx.ctx_ = ctx.SUBNET4; }
-#line 739 "dhcp4_parser.cc" // lalr1.cc:856
+#line 762 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 12:
-#line 260 "dhcp4_parser.yy" // lalr1.cc:856
+#line 260 "dhcp4_parser.yy" // lalr1.cc:907
{ ctx.ctx_ = ctx.POOLS; }
-#line 745 "dhcp4_parser.cc" // lalr1.cc:856
+#line 768 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 14:
-#line 261 "dhcp4_parser.yy" // lalr1.cc:856
+#line 261 "dhcp4_parser.yy" // lalr1.cc:907
{ ctx.ctx_ = ctx.RESERVATIONS; }
-#line 751 "dhcp4_parser.cc" // lalr1.cc:856
+#line 774 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 16:
-#line 262 "dhcp4_parser.yy" // lalr1.cc:856
+#line 262 "dhcp4_parser.yy" // lalr1.cc:907
{ ctx.ctx_ = ctx.DHCP4; }
-#line 757 "dhcp4_parser.cc" // lalr1.cc:856
+#line 780 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 18:
-#line 263 "dhcp4_parser.yy" // lalr1.cc:856
+#line 263 "dhcp4_parser.yy" // lalr1.cc:907
{ ctx.ctx_ = ctx.OPTION_DEF; }
-#line 763 "dhcp4_parser.cc" // lalr1.cc:856
+#line 786 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 20:
-#line 264 "dhcp4_parser.yy" // lalr1.cc:856
+#line 264 "dhcp4_parser.yy" // lalr1.cc:907
{ ctx.ctx_ = ctx.OPTION_DATA; }
-#line 769 "dhcp4_parser.cc" // lalr1.cc:856
+#line 792 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 22:
-#line 265 "dhcp4_parser.yy" // lalr1.cc:856
+#line 265 "dhcp4_parser.yy" // lalr1.cc:907
{ ctx.ctx_ = ctx.HOOKS_LIBRARIES; }
-#line 775 "dhcp4_parser.cc" // lalr1.cc:856
+#line 798 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 24:
-#line 266 "dhcp4_parser.yy" // lalr1.cc:856
+#line 266 "dhcp4_parser.yy" // lalr1.cc:907
{ ctx.ctx_ = ctx.DHCP_DDNS; }
-#line 781 "dhcp4_parser.cc" // lalr1.cc:856
+#line 804 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 26:
-#line 267 "dhcp4_parser.yy" // lalr1.cc:856
+#line 267 "dhcp4_parser.yy" // lalr1.cc:907
{ ctx.ctx_ = ctx.LOGGING; }
-#line 787 "dhcp4_parser.cc" // lalr1.cc:856
+#line 810 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 28:
-#line 268 "dhcp4_parser.yy" // lalr1.cc:856
+#line 268 "dhcp4_parser.yy" // lalr1.cc:907
{ ctx.ctx_ = ctx.CONFIG_CONTROL; }
-#line 793 "dhcp4_parser.cc" // lalr1.cc:856
+#line 816 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 30:
-#line 276 "dhcp4_parser.yy" // lalr1.cc:856
+#line 276 "dhcp4_parser.yy" // lalr1.cc:907
{ yylhs.value.as< ElementPtr > () = ElementPtr(new IntElement(yystack_[0].value.as< int64_t > (), ctx.loc2pos(yystack_[0].location))); }
-#line 799 "dhcp4_parser.cc" // lalr1.cc:856
+#line 822 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 31:
-#line 277 "dhcp4_parser.yy" // lalr1.cc:856
+#line 277 "dhcp4_parser.yy" // lalr1.cc:907
{ yylhs.value.as< ElementPtr > () = ElementPtr(new DoubleElement(yystack_[0].value.as< double > (), ctx.loc2pos(yystack_[0].location))); }
-#line 805 "dhcp4_parser.cc" // lalr1.cc:856
+#line 828 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 32:
-#line 278 "dhcp4_parser.yy" // lalr1.cc:856
+#line 278 "dhcp4_parser.yy" // lalr1.cc:907
{ yylhs.value.as< ElementPtr > () = ElementPtr(new BoolElement(yystack_[0].value.as< bool > (), ctx.loc2pos(yystack_[0].location))); }
-#line 811 "dhcp4_parser.cc" // lalr1.cc:856
+#line 834 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 33:
-#line 279 "dhcp4_parser.yy" // lalr1.cc:856
+#line 279 "dhcp4_parser.yy" // lalr1.cc:907
{ yylhs.value.as< ElementPtr > () = ElementPtr(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location))); }
-#line 817 "dhcp4_parser.cc" // lalr1.cc:856
+#line 840 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 34:
-#line 280 "dhcp4_parser.yy" // lalr1.cc:856
+#line 280 "dhcp4_parser.yy" // lalr1.cc:907
{ yylhs.value.as< ElementPtr > () = ElementPtr(new NullElement(ctx.loc2pos(yystack_[0].location))); }
-#line 823 "dhcp4_parser.cc" // lalr1.cc:856
+#line 846 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 35:
-#line 281 "dhcp4_parser.yy" // lalr1.cc:856
+#line 281 "dhcp4_parser.yy" // lalr1.cc:907
{ yylhs.value.as< ElementPtr > () = ctx.stack_.back(); ctx.stack_.pop_back(); }
-#line 829 "dhcp4_parser.cc" // lalr1.cc:856
+#line 852 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 36:
-#line 282 "dhcp4_parser.yy" // lalr1.cc:856
+#line 282 "dhcp4_parser.yy" // lalr1.cc:907
{ yylhs.value.as< ElementPtr > () = ctx.stack_.back(); ctx.stack_.pop_back(); }
-#line 835 "dhcp4_parser.cc" // lalr1.cc:856
+#line 858 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 37:
-#line 285 "dhcp4_parser.yy" // lalr1.cc:856
+#line 285 "dhcp4_parser.yy" // lalr1.cc:907
{
// Push back the JSON value on the stack
ctx.stack_.push_back(yystack_[0].value.as< ElementPtr > ());
}
-#line 844 "dhcp4_parser.cc" // lalr1.cc:856
+#line 867 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 38:
-#line 290 "dhcp4_parser.yy" // lalr1.cc:856
+#line 290 "dhcp4_parser.yy" // lalr1.cc:907
{
// This code is executed when we're about to start parsing
// the content of the map
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.push_back(m);
}
-#line 855 "dhcp4_parser.cc" // lalr1.cc:856
+#line 878 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 39:
-#line 295 "dhcp4_parser.yy" // lalr1.cc:856
+#line 295 "dhcp4_parser.yy" // lalr1.cc:907
{
// map parsing completed. If we ever want to do any wrap up
// (maybe some sanity checking), this would be the best place
// for it.
}
-#line 865 "dhcp4_parser.cc" // lalr1.cc:856
+#line 888 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 40:
-#line 301 "dhcp4_parser.yy" // lalr1.cc:856
+#line 301 "dhcp4_parser.yy" // lalr1.cc:907
{ yylhs.value.as< ElementPtr > () = ctx.stack_.back(); ctx.stack_.pop_back(); }
-#line 871 "dhcp4_parser.cc" // lalr1.cc:856
+#line 894 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 43:
-#line 308 "dhcp4_parser.yy" // lalr1.cc:856
+#line 308 "dhcp4_parser.yy" // lalr1.cc:907
{
// map containing a single entry
ctx.stack_.back()->set(yystack_[2].value.as< std::string > (), yystack_[0].value.as< ElementPtr > ());
}
-#line 880 "dhcp4_parser.cc" // lalr1.cc:856
+#line 903 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 44:
-#line 312 "dhcp4_parser.yy" // lalr1.cc:856
+#line 312 "dhcp4_parser.yy" // lalr1.cc:907
{
// map consisting of a shorter map followed by
// comma and string:value
ctx.stack_.back()->set(yystack_[2].value.as< std::string > (), yystack_[0].value.as< ElementPtr > ());
}
-#line 890 "dhcp4_parser.cc" // lalr1.cc:856
+#line 913 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 45:
-#line 319 "dhcp4_parser.yy" // lalr1.cc:856
+#line 319 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr l(new ListElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.push_back(l);
}
-#line 899 "dhcp4_parser.cc" // lalr1.cc:856
+#line 922 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 46:
-#line 322 "dhcp4_parser.yy" // lalr1.cc:856
+#line 322 "dhcp4_parser.yy" // lalr1.cc:907
{
// list parsing complete. Put any sanity checking here
}
-#line 907 "dhcp4_parser.cc" // lalr1.cc:856
+#line 930 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 49:
-#line 330 "dhcp4_parser.yy" // lalr1.cc:856
+#line 330 "dhcp4_parser.yy" // lalr1.cc:907
{
// List consisting of a single element.
ctx.stack_.back()->add(yystack_[0].value.as< ElementPtr > ());
}
-#line 916 "dhcp4_parser.cc" // lalr1.cc:856
+#line 939 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 50:
-#line 334 "dhcp4_parser.yy" // lalr1.cc:856
+#line 334 "dhcp4_parser.yy" // lalr1.cc:907
{
// List ending with , and a value.
ctx.stack_.back()->add(yystack_[0].value.as< ElementPtr > ());
}
-#line 925 "dhcp4_parser.cc" // lalr1.cc:856
+#line 948 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 51:
-#line 341 "dhcp4_parser.yy" // lalr1.cc:856
+#line 341 "dhcp4_parser.yy" // lalr1.cc:907
{
// List parsing about to start
}
-#line 933 "dhcp4_parser.cc" // lalr1.cc:856
+#line 956 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 52:
-#line 343 "dhcp4_parser.yy" // lalr1.cc:856
+#line 343 "dhcp4_parser.yy" // lalr1.cc:907
{
// list parsing complete. Put any sanity checking here
//ctx.stack_.pop_back();
}
-#line 942 "dhcp4_parser.cc" // lalr1.cc:856
+#line 965 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 55:
-#line 352 "dhcp4_parser.yy" // lalr1.cc:856
+#line 352 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr s(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->add(s);
}
-#line 951 "dhcp4_parser.cc" // lalr1.cc:856
+#line 974 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 56:
-#line 356 "dhcp4_parser.yy" // lalr1.cc:856
+#line 356 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr s(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->add(s);
}
-#line 960 "dhcp4_parser.cc" // lalr1.cc:856
+#line 983 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 57:
-#line 367 "dhcp4_parser.yy" // lalr1.cc:856
+#line 367 "dhcp4_parser.yy" // lalr1.cc:907
{
const std::string& where = ctx.contextName();
const std::string& keyword = yystack_[1].value.as< std::string > ();
error(yystack_[1].location,
"got unexpected keyword \"" + keyword + "\" in " + where + " map.");
}
-#line 971 "dhcp4_parser.cc" // lalr1.cc:856
+#line 994 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 58:
-#line 377 "dhcp4_parser.yy" // lalr1.cc:856
+#line 377 "dhcp4_parser.yy" // lalr1.cc:907
{
// This code is executed when we're about to start parsing
// the content of the map
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.push_back(m);
}
-#line 982 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1005 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 59:
-#line 382 "dhcp4_parser.yy" // lalr1.cc:856
+#line 382 "dhcp4_parser.yy" // lalr1.cc:907
{
// map parsing completed. If we ever want to do any wrap up
// (maybe some sanity checking), this would be the best place
// Dhcp4 is required
ctx.require("Dhcp4", ctx.loc2pos(yystack_[3].location), ctx.loc2pos(yystack_[0].location));
}
-#line 995 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1018 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 68:
-#line 406 "dhcp4_parser.yy" // lalr1.cc:856
+#line 406 "dhcp4_parser.yy" // lalr1.cc:907
{
// This code is executed when we're about to start parsing
// the content of the map
ctx.stack_.push_back(m);
ctx.enter(ctx.DHCP4);
}
-#line 1008 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1031 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 69:
-#line 413 "dhcp4_parser.yy" // lalr1.cc:856
+#line 413 "dhcp4_parser.yy" // lalr1.cc:907
{
// No global parameter is required
ctx.stack_.pop_back();
ctx.leave();
}
-#line 1018 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1041 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 70:
-#line 421 "dhcp4_parser.yy" // lalr1.cc:856
+#line 421 "dhcp4_parser.yy" // lalr1.cc:907
{
// Parse the Dhcp4 map
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.push_back(m);
}
-#line 1028 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1051 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 71:
-#line 425 "dhcp4_parser.yy" // lalr1.cc:856
+#line 425 "dhcp4_parser.yy" // lalr1.cc:907
{
// No global parameter is required
// parsing completed
}
-#line 1037 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1060 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 107:
-#line 471 "dhcp4_parser.yy" // lalr1.cc:856
+#line 471 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr prf(new IntElement(yystack_[0].value.as< int64_t > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("valid-lifetime", prf);
}
-#line 1046 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1069 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 108:
-#line 476 "dhcp4_parser.yy" // lalr1.cc:856
+#line 476 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr prf(new IntElement(yystack_[0].value.as< int64_t > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("renew-timer", prf);
}
-#line 1055 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1078 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 109:
-#line 481 "dhcp4_parser.yy" // lalr1.cc:856
+#line 481 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr prf(new IntElement(yystack_[0].value.as< int64_t > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("rebind-timer", prf);
}
-#line 1064 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1087 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 110:
-#line 486 "dhcp4_parser.yy" // lalr1.cc:856
+#line 486 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr dpp(new IntElement(yystack_[0].value.as< int64_t > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("decline-probation-period", dpp);
}
-#line 1073 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1096 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 111:
-#line 491 "dhcp4_parser.yy" // lalr1.cc:856
+#line 491 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 1081 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1104 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 112:
-#line 493 "dhcp4_parser.yy" // lalr1.cc:856
+#line 493 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr stag(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("server-tag", stag);
ctx.leave();
}
-#line 1091 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1114 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 113:
-#line 499 "dhcp4_parser.yy" // lalr1.cc:856
+#line 499 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr echo(new BoolElement(yystack_[0].value.as< bool > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("echo-client-id", echo);
}
-#line 1100 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1123 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 114:
-#line 504 "dhcp4_parser.yy" // lalr1.cc:856
+#line 504 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr match(new BoolElement(yystack_[0].value.as< bool > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("match-client-id", match);
}
-#line 1109 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1132 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 115:
-#line 509 "dhcp4_parser.yy" // lalr1.cc:856
+#line 509 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr prf(new BoolElement(yystack_[0].value.as< bool > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("authoritative", prf);
}
-#line 1118 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1141 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 116:
-#line 515 "dhcp4_parser.yy" // lalr1.cc:856
+#line 515 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr i(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("interfaces-config", i);
ctx.stack_.push_back(i);
ctx.enter(ctx.INTERFACES_CONFIG);
}
-#line 1129 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1152 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 117:
-#line 520 "dhcp4_parser.yy" // lalr1.cc:856
+#line 520 "dhcp4_parser.yy" // lalr1.cc:907
{
// No interfaces config param is required
ctx.stack_.pop_back();
ctx.leave();
}
-#line 1139 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1162 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 127:
-#line 539 "dhcp4_parser.yy" // lalr1.cc:856
+#line 539 "dhcp4_parser.yy" // lalr1.cc:907
{
// Parse the interfaces-config map
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.push_back(m);
}
-#line 1149 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1172 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 128:
-#line 543 "dhcp4_parser.yy" // lalr1.cc:856
+#line 543 "dhcp4_parser.yy" // lalr1.cc:907
{
// No interfaces config param is required
// parsing completed
}
-#line 1158 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1181 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 129:
-#line 548 "dhcp4_parser.yy" // lalr1.cc:856
+#line 548 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr l(new ListElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("interfaces", l);
ctx.stack_.push_back(l);
ctx.enter(ctx.NO_KEYWORD);
}
-#line 1169 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1192 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 130:
-#line 553 "dhcp4_parser.yy" // lalr1.cc:856
+#line 553 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
ctx.leave();
}
-#line 1178 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1201 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 131:
-#line 558 "dhcp4_parser.yy" // lalr1.cc:856
+#line 558 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.DHCP_SOCKET_TYPE);
}
-#line 1186 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1209 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 132:
-#line 560 "dhcp4_parser.yy" // lalr1.cc:856
+#line 560 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.stack_.back()->set("dhcp-socket-type", yystack_[0].value.as< ElementPtr > ());
ctx.leave();
}
-#line 1195 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1218 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 133:
-#line 565 "dhcp4_parser.yy" // lalr1.cc:856
+#line 565 "dhcp4_parser.yy" // lalr1.cc:907
{ yylhs.value.as< ElementPtr > () = ElementPtr(new StringElement("raw", ctx.loc2pos(yystack_[0].location))); }
-#line 1201 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1224 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 134:
-#line 566 "dhcp4_parser.yy" // lalr1.cc:856
+#line 566 "dhcp4_parser.yy" // lalr1.cc:907
{ yylhs.value.as< ElementPtr > () = ElementPtr(new StringElement("udp", ctx.loc2pos(yystack_[0].location))); }
-#line 1207 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1230 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 135:
-#line 569 "dhcp4_parser.yy" // lalr1.cc:856
+#line 569 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.OUTBOUND_INTERFACE);
}
-#line 1215 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1238 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 136:
-#line 571 "dhcp4_parser.yy" // lalr1.cc:856
+#line 571 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.stack_.back()->set("outbound-interface", yystack_[0].value.as< ElementPtr > ());
ctx.leave();
}
-#line 1224 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1247 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 137:
-#line 576 "dhcp4_parser.yy" // lalr1.cc:856
+#line 576 "dhcp4_parser.yy" // lalr1.cc:907
{
yylhs.value.as< ElementPtr > () = ElementPtr(new StringElement("same-as-inbound", ctx.loc2pos(yystack_[0].location)));
}
-#line 1232 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1255 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 138:
-#line 578 "dhcp4_parser.yy" // lalr1.cc:856
+#line 578 "dhcp4_parser.yy" // lalr1.cc:907
{
yylhs.value.as< ElementPtr > () = ElementPtr(new StringElement("use-routing", ctx.loc2pos(yystack_[0].location)));
}
-#line 1240 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1263 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 139:
-#line 582 "dhcp4_parser.yy" // lalr1.cc:856
+#line 582 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr b(new BoolElement(yystack_[0].value.as< bool > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("re-detect", b);
}
-#line 1249 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1272 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 140:
-#line 588 "dhcp4_parser.yy" // lalr1.cc:856
+#line 588 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr i(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("lease-database", i);
ctx.stack_.push_back(i);
ctx.enter(ctx.LEASE_DATABASE);
}
-#line 1260 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1283 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 141:
-#line 593 "dhcp4_parser.yy" // lalr1.cc:856
+#line 593 "dhcp4_parser.yy" // lalr1.cc:907
{
// The type parameter is required
ctx.require("type", ctx.loc2pos(yystack_[2].location), ctx.loc2pos(yystack_[0].location));
ctx.stack_.pop_back();
ctx.leave();
}
-#line 1271 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1294 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 142:
-#line 600 "dhcp4_parser.yy" // lalr1.cc:856
+#line 600 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("sanity-checks", m);
ctx.stack_.push_back(m);
ctx.enter(ctx.SANITY_CHECKS);
}
-#line 1282 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1305 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 143:
-#line 605 "dhcp4_parser.yy" // lalr1.cc:856
+#line 605 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
ctx.leave();
}
-#line 1291 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1314 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 147:
-#line 615 "dhcp4_parser.yy" // lalr1.cc:856
+#line 615 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 1299 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1322 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 148:
-#line 617 "dhcp4_parser.yy" // lalr1.cc:856
+#line 617 "dhcp4_parser.yy" // lalr1.cc:907
{
if ( (string(yystack_[0].value.as< std::string > ()) == "none") ||
", supported values are: none, warn, fix, fix-del, del");
}
}
-#line 1319 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1342 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 149:
-#line 633 "dhcp4_parser.yy" // lalr1.cc:856
+#line 633 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr i(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("hosts-database", i);
ctx.stack_.push_back(i);
ctx.enter(ctx.HOSTS_DATABASE);
}
-#line 1330 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1353 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 150:
-#line 638 "dhcp4_parser.yy" // lalr1.cc:856
+#line 638 "dhcp4_parser.yy" // lalr1.cc:907
{
// The type parameter is required
ctx.require("type", ctx.loc2pos(yystack_[2].location), ctx.loc2pos(yystack_[0].location));
ctx.stack_.pop_back();
ctx.leave();
}
-#line 1341 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1364 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 151:
-#line 645 "dhcp4_parser.yy" // lalr1.cc:856
+#line 645 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr l(new ListElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("hosts-databases", l);
ctx.stack_.push_back(l);
ctx.enter(ctx.HOSTS_DATABASE);
}
-#line 1352 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1375 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 152:
-#line 650 "dhcp4_parser.yy" // lalr1.cc:856
+#line 650 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
ctx.leave();
}
-#line 1361 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1384 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 157:
-#line 663 "dhcp4_parser.yy" // lalr1.cc:856
+#line 663 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->add(m);
ctx.stack_.push_back(m);
}
-#line 1371 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1394 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 158:
-#line 667 "dhcp4_parser.yy" // lalr1.cc:856
+#line 667 "dhcp4_parser.yy" // lalr1.cc:907
{
// The type parameter is required
ctx.require("type", ctx.loc2pos(yystack_[3].location), ctx.loc2pos(yystack_[0].location));
ctx.stack_.pop_back();
}
-#line 1381 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1404 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 179:
-#line 697 "dhcp4_parser.yy" // lalr1.cc:856
+#line 697 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.DATABASE_TYPE);
}
-#line 1389 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1412 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 180:
-#line 699 "dhcp4_parser.yy" // lalr1.cc:856
+#line 699 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.stack_.back()->set("type", yystack_[0].value.as< ElementPtr > ());
ctx.leave();
}
-#line 1398 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1421 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 181:
-#line 704 "dhcp4_parser.yy" // lalr1.cc:856
+#line 704 "dhcp4_parser.yy" // lalr1.cc:907
{ yylhs.value.as< ElementPtr > () = ElementPtr(new StringElement("memfile", ctx.loc2pos(yystack_[0].location))); }
-#line 1404 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1427 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 182:
-#line 705 "dhcp4_parser.yy" // lalr1.cc:856
+#line 705 "dhcp4_parser.yy" // lalr1.cc:907
{ yylhs.value.as< ElementPtr > () = ElementPtr(new StringElement("mysql", ctx.loc2pos(yystack_[0].location))); }
-#line 1410 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1433 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 183:
-#line 706 "dhcp4_parser.yy" // lalr1.cc:856
+#line 706 "dhcp4_parser.yy" // lalr1.cc:907
{ yylhs.value.as< ElementPtr > () = ElementPtr(new StringElement("postgresql", ctx.loc2pos(yystack_[0].location))); }
-#line 1416 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1439 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 184:
-#line 707 "dhcp4_parser.yy" // lalr1.cc:856
+#line 707 "dhcp4_parser.yy" // lalr1.cc:907
{ yylhs.value.as< ElementPtr > () = ElementPtr(new StringElement("cql", ctx.loc2pos(yystack_[0].location))); }
-#line 1422 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1445 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 185:
-#line 710 "dhcp4_parser.yy" // lalr1.cc:856
+#line 710 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 1430 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1453 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 186:
-#line 712 "dhcp4_parser.yy" // lalr1.cc:856
+#line 712 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr user(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("user", user);
ctx.leave();
}
-#line 1440 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1463 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 187:
-#line 718 "dhcp4_parser.yy" // lalr1.cc:856
+#line 718 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 1448 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1471 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 188:
-#line 720 "dhcp4_parser.yy" // lalr1.cc:856
+#line 720 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr pwd(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("password", pwd);
ctx.leave();
}
-#line 1458 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1481 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 189:
-#line 726 "dhcp4_parser.yy" // lalr1.cc:856
+#line 726 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 1466 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1489 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 190:
-#line 728 "dhcp4_parser.yy" // lalr1.cc:856
+#line 728 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr h(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("host", h);
ctx.leave();
}
-#line 1476 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1499 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 191:
-#line 734 "dhcp4_parser.yy" // lalr1.cc:856
+#line 734 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr p(new IntElement(yystack_[0].value.as< int64_t > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("port", p);
}
-#line 1485 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1508 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 192:
-#line 739 "dhcp4_parser.yy" // lalr1.cc:856
+#line 739 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 1493 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1516 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 193:
-#line 741 "dhcp4_parser.yy" // lalr1.cc:856
+#line 741 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr name(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("name", name);
ctx.leave();
}
-#line 1503 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1526 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 194:
-#line 747 "dhcp4_parser.yy" // lalr1.cc:856
+#line 747 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr n(new BoolElement(yystack_[0].value.as< bool > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("persist", n);
}
-#line 1512 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1535 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 195:
-#line 752 "dhcp4_parser.yy" // lalr1.cc:856
+#line 752 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr n(new IntElement(yystack_[0].value.as< int64_t > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("lfc-interval", n);
}
-#line 1521 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1544 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 196:
-#line 757 "dhcp4_parser.yy" // lalr1.cc:856
+#line 757 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr n(new BoolElement(yystack_[0].value.as< bool > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("readonly", n);
}
-#line 1530 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1553 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 197:
-#line 762 "dhcp4_parser.yy" // lalr1.cc:856
+#line 762 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr n(new IntElement(yystack_[0].value.as< int64_t > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("connect-timeout", n);
}
-#line 1539 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1562 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 198:
-#line 767 "dhcp4_parser.yy" // lalr1.cc:856
+#line 767 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr n(new IntElement(yystack_[0].value.as< int64_t > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("request-timeout", n);
}
-#line 1548 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1571 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 199:
-#line 772 "dhcp4_parser.yy" // lalr1.cc:856
+#line 772 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr n(new IntElement(yystack_[0].value.as< int64_t > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("tcp-keepalive", n);
}
-#line 1557 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1580 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 200:
-#line 777 "dhcp4_parser.yy" // lalr1.cc:856
+#line 777 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr n(new BoolElement(yystack_[0].value.as< bool > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("tcp-nodelay", n);
}
-#line 1566 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1589 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 201:
-#line 782 "dhcp4_parser.yy" // lalr1.cc:856
+#line 782 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 1574 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1597 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 202:
-#line 784 "dhcp4_parser.yy" // lalr1.cc:856
+#line 784 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr cp(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("contact-points", cp);
ctx.leave();
}
-#line 1584 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1607 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 203:
-#line 790 "dhcp4_parser.yy" // lalr1.cc:856
+#line 790 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 1592 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1615 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 204:
-#line 792 "dhcp4_parser.yy" // lalr1.cc:856
+#line 792 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr ks(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("keyspace", ks);
ctx.leave();
}
-#line 1602 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1625 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 205:
-#line 798 "dhcp4_parser.yy" // lalr1.cc:856
+#line 798 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr n(new IntElement(yystack_[0].value.as< int64_t > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("max-reconnect-tries", n);
}
-#line 1611 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1634 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 206:
-#line 803 "dhcp4_parser.yy" // lalr1.cc:856
+#line 803 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr n(new IntElement(yystack_[0].value.as< int64_t > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("reconnect-wait-time", n);
}
-#line 1620 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1643 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 207:
-#line 808 "dhcp4_parser.yy" // lalr1.cc:856
+#line 808 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr l(new ListElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("host-reservation-identifiers", l);
ctx.stack_.push_back(l);
ctx.enter(ctx.HOST_RESERVATION_IDENTIFIERS);
}
-#line 1631 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1654 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 208:
-#line 813 "dhcp4_parser.yy" // lalr1.cc:856
+#line 813 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
ctx.leave();
}
-#line 1640 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1663 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 216:
-#line 829 "dhcp4_parser.yy" // lalr1.cc:856
+#line 829 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr duid(new StringElement("duid", ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->add(duid);
}
-#line 1649 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1672 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 217:
-#line 834 "dhcp4_parser.yy" // lalr1.cc:856
+#line 834 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr hwaddr(new StringElement("hw-address", ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->add(hwaddr);
}
-#line 1658 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1681 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 218:
-#line 839 "dhcp4_parser.yy" // lalr1.cc:856
+#line 839 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr circuit(new StringElement("circuit-id", ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->add(circuit);
}
-#line 1667 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1690 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 219:
-#line 844 "dhcp4_parser.yy" // lalr1.cc:856
+#line 844 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr client(new StringElement("client-id", ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->add(client);
}
-#line 1676 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1699 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 220:
-#line 849 "dhcp4_parser.yy" // lalr1.cc:856
+#line 849 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr flex_id(new StringElement("flex-id", ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->add(flex_id);
}
-#line 1685 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1708 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 221:
-#line 854 "dhcp4_parser.yy" // lalr1.cc:856
+#line 854 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr l(new ListElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("hooks-libraries", l);
ctx.stack_.push_back(l);
ctx.enter(ctx.HOOKS_LIBRARIES);
}
-#line 1696 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1719 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 222:
-#line 859 "dhcp4_parser.yy" // lalr1.cc:856
+#line 859 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
ctx.leave();
}
-#line 1705 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1728 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 227:
-#line 872 "dhcp4_parser.yy" // lalr1.cc:856
+#line 872 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->add(m);
ctx.stack_.push_back(m);
}
-#line 1715 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1738 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 228:
-#line 876 "dhcp4_parser.yy" // lalr1.cc:856
+#line 876 "dhcp4_parser.yy" // lalr1.cc:907
{
// The library hooks parameter is required
ctx.require("library", ctx.loc2pos(yystack_[3].location), ctx.loc2pos(yystack_[0].location));
ctx.stack_.pop_back();
}
-#line 1725 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1748 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 229:
-#line 882 "dhcp4_parser.yy" // lalr1.cc:856
+#line 882 "dhcp4_parser.yy" // lalr1.cc:907
{
// Parse the hooks-libraries list entry map
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.push_back(m);
}
-#line 1735 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1758 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 230:
-#line 886 "dhcp4_parser.yy" // lalr1.cc:856
+#line 886 "dhcp4_parser.yy" // lalr1.cc:907
{
// The library hooks parameter is required
ctx.require("library", ctx.loc2pos(yystack_[3].location), ctx.loc2pos(yystack_[0].location));
// parsing completed
}
-#line 1745 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1768 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 236:
-#line 901 "dhcp4_parser.yy" // lalr1.cc:856
+#line 901 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 1753 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1776 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 237:
-#line 903 "dhcp4_parser.yy" // lalr1.cc:856
+#line 903 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr lib(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("library", lib);
ctx.leave();
}
-#line 1763 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1786 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 238:
-#line 909 "dhcp4_parser.yy" // lalr1.cc:856
+#line 909 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 1771 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1794 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 239:
-#line 911 "dhcp4_parser.yy" // lalr1.cc:856
+#line 911 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.stack_.back()->set("parameters", yystack_[0].value.as< ElementPtr > ());
ctx.leave();
}
-#line 1780 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1803 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 240:
-#line 917 "dhcp4_parser.yy" // lalr1.cc:856
+#line 917 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("expired-leases-processing", m);
ctx.stack_.push_back(m);
ctx.enter(ctx.EXPIRED_LEASES_PROCESSING);
}
-#line 1791 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1814 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 241:
-#line 922 "dhcp4_parser.yy" // lalr1.cc:856
+#line 922 "dhcp4_parser.yy" // lalr1.cc:907
{
// No expired lease parameter is required
ctx.stack_.pop_back();
ctx.leave();
}
-#line 1801 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1824 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 250:
-#line 940 "dhcp4_parser.yy" // lalr1.cc:856
+#line 940 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr value(new IntElement(yystack_[0].value.as< int64_t > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("reclaim-timer-wait-time", value);
}
-#line 1810 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1833 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 251:
-#line 945 "dhcp4_parser.yy" // lalr1.cc:856
+#line 945 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr value(new IntElement(yystack_[0].value.as< int64_t > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("flush-reclaimed-timer-wait-time", value);
}
-#line 1819 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1842 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 252:
-#line 950 "dhcp4_parser.yy" // lalr1.cc:856
+#line 950 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr value(new IntElement(yystack_[0].value.as< int64_t > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("hold-reclaimed-time", value);
}
-#line 1828 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1851 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 253:
-#line 955 "dhcp4_parser.yy" // lalr1.cc:856
+#line 955 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr value(new IntElement(yystack_[0].value.as< int64_t > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("max-reclaim-leases", value);
}
-#line 1837 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1860 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 254:
-#line 960 "dhcp4_parser.yy" // lalr1.cc:856
+#line 960 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr value(new IntElement(yystack_[0].value.as< int64_t > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("max-reclaim-time", value);
}
-#line 1846 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1869 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 255:
-#line 965 "dhcp4_parser.yy" // lalr1.cc:856
+#line 965 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr value(new IntElement(yystack_[0].value.as< int64_t > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("unwarned-reclaim-cycles", value);
}
-#line 1855 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1878 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 256:
-#line 973 "dhcp4_parser.yy" // lalr1.cc:856
+#line 973 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr l(new ListElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("subnet4", l);
ctx.stack_.push_back(l);
ctx.enter(ctx.SUBNET4);
}
-#line 1866 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1889 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 257:
-#line 978 "dhcp4_parser.yy" // lalr1.cc:856
+#line 978 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
ctx.leave();
}
-#line 1875 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1898 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 262:
-#line 998 "dhcp4_parser.yy" // lalr1.cc:856
+#line 998 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->add(m);
ctx.stack_.push_back(m);
}
-#line 1885 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1908 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 263:
-#line 1002 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1002 "dhcp4_parser.yy" // lalr1.cc:907
{
// Once we reached this place, the subnet parsing is now complete.
// If we want to, we can implement default values here.
ctx.require("subnet", ctx.loc2pos(yystack_[3].location), ctx.loc2pos(yystack_[0].location));
ctx.stack_.pop_back();
}
-#line 1911 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1934 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 264:
-#line 1024 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1024 "dhcp4_parser.yy" // lalr1.cc:907
{
// Parse the subnet4 list entry map
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.push_back(m);
}
-#line 1921 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1944 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 265:
-#line 1028 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1028 "dhcp4_parser.yy" // lalr1.cc:907
{
// The subnet subnet4 parameter is required
ctx.require("subnet", ctx.loc2pos(yystack_[3].location), ctx.loc2pos(yystack_[0].location));
// parsing completed
}
-#line 1931 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1954 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 292:
-#line 1066 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1066 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 1939 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1962 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 293:
-#line 1068 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1068 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr subnet(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("subnet", subnet);
ctx.leave();
}
-#line 1949 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1972 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 294:
-#line 1074 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1074 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 1957 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1980 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 295:
-#line 1076 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1076 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr iface(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("4o6-interface", iface);
ctx.leave();
}
-#line 1967 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1990 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 296:
-#line 1082 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1082 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 1975 "dhcp4_parser.cc" // lalr1.cc:856
+#line 1998 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 297:
-#line 1084 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1084 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr iface(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("4o6-interface-id", iface);
ctx.leave();
}
-#line 1985 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2008 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 298:
-#line 1090 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1090 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 1993 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2016 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 299:
-#line 1092 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1092 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr iface(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("4o6-subnet", iface);
ctx.leave();
}
-#line 2003 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2026 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 300:
-#line 1098 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1098 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 2011 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2034 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 301:
-#line 1100 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1100 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr iface(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("interface", iface);
ctx.leave();
}
-#line 2021 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2044 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 302:
-#line 1106 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1106 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 2029 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2052 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 303:
-#line 1108 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1108 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr cls(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("client-class", cls);
ctx.leave();
}
-#line 2039 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2062 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 304:
-#line 1114 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1114 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr c(new ListElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("require-client-classes", c);
ctx.stack_.push_back(c);
ctx.enter(ctx.NO_KEYWORD);
}
-#line 2050 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2073 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 305:
-#line 1119 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1119 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
ctx.leave();
}
-#line 2059 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2082 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 306:
-#line 1124 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1124 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.RESERVATION_MODE);
}
-#line 2067 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2090 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 307:
-#line 1126 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1126 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.stack_.back()->set("reservation-mode", yystack_[0].value.as< ElementPtr > ());
ctx.leave();
}
-#line 2076 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2099 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 308:
-#line 1131 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1131 "dhcp4_parser.yy" // lalr1.cc:907
{ yylhs.value.as< ElementPtr > () = ElementPtr(new StringElement("disabled", ctx.loc2pos(yystack_[0].location))); }
-#line 2082 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2105 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 309:
-#line 1132 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1132 "dhcp4_parser.yy" // lalr1.cc:907
{ yylhs.value.as< ElementPtr > () = ElementPtr(new StringElement("out-of-pool", ctx.loc2pos(yystack_[0].location))); }
-#line 2088 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2111 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 310:
-#line 1133 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1133 "dhcp4_parser.yy" // lalr1.cc:907
{ yylhs.value.as< ElementPtr > () = ElementPtr(new StringElement("global", ctx.loc2pos(yystack_[0].location))); }
-#line 2094 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2117 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 311:
-#line 1134 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1134 "dhcp4_parser.yy" // lalr1.cc:907
{ yylhs.value.as< ElementPtr > () = ElementPtr(new StringElement("all", ctx.loc2pos(yystack_[0].location))); }
-#line 2100 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2123 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 312:
-#line 1137 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1137 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr id(new IntElement(yystack_[0].value.as< int64_t > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("id", id);
}
-#line 2109 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2132 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 313:
-#line 1144 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1144 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr l(new ListElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("shared-networks", l);
ctx.stack_.push_back(l);
ctx.enter(ctx.SHARED_NETWORK);
}
-#line 2120 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2143 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 314:
-#line 1149 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1149 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
ctx.leave();
}
-#line 2129 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2152 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 319:
-#line 1164 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1164 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->add(m);
ctx.stack_.push_back(m);
}
-#line 2139 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2162 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 320:
-#line 1168 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1168 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
}
-#line 2147 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2170 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 342:
-#line 1201 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1201 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr l(new ListElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("option-def", l);
ctx.stack_.push_back(l);
ctx.enter(ctx.OPTION_DEF);
}
-#line 2158 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2181 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 343:
-#line 1206 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1206 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
ctx.leave();
}
-#line 2167 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2190 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 344:
-#line 1214 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1214 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.push_back(m);
}
-#line 2176 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2199 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 345:
-#line 1217 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1217 "dhcp4_parser.yy" // lalr1.cc:907
{
// parsing completed
}
-#line 2184 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2207 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 350:
-#line 1233 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1233 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->add(m);
ctx.stack_.push_back(m);
}
-#line 2194 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2217 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 351:
-#line 1237 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1237 "dhcp4_parser.yy" // lalr1.cc:907
{
// The name, code and type option def parameters are required.
ctx.require("name", ctx.loc2pos(yystack_[3].location), ctx.loc2pos(yystack_[0].location));
ctx.require("type", ctx.loc2pos(yystack_[3].location), ctx.loc2pos(yystack_[0].location));
ctx.stack_.pop_back();
}
-#line 2206 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2229 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 352:
-#line 1248 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1248 "dhcp4_parser.yy" // lalr1.cc:907
{
// Parse the option-def list entry map
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.push_back(m);
}
-#line 2216 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2239 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 353:
-#line 1252 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1252 "dhcp4_parser.yy" // lalr1.cc:907
{
// The name, code and type option def parameters are required.
ctx.require("name", ctx.loc2pos(yystack_[3].location), ctx.loc2pos(yystack_[0].location));
ctx.require("type", ctx.loc2pos(yystack_[3].location), ctx.loc2pos(yystack_[0].location));
// parsing completed
}
-#line 2228 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2251 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 369:
-#line 1284 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1284 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr code(new IntElement(yystack_[0].value.as< int64_t > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("code", code);
}
-#line 2237 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2260 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 371:
-#line 1291 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1291 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 2245 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2268 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 372:
-#line 1293 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1293 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr prf(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("type", prf);
ctx.leave();
}
-#line 2255 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2278 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 373:
-#line 1299 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1299 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 2263 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2286 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 374:
-#line 1301 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1301 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr rtypes(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("record-types", rtypes);
ctx.leave();
}
-#line 2273 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2296 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 375:
-#line 1307 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1307 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 2281 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2304 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 376:
-#line 1309 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1309 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr space(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("space", space);
ctx.leave();
}
-#line 2291 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2314 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 378:
-#line 1317 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1317 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 2299 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2322 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 379:
-#line 1319 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1319 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr encap(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("encapsulate", encap);
ctx.leave();
}
-#line 2309 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2332 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 380:
-#line 1325 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1325 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr array(new BoolElement(yystack_[0].value.as< bool > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("array", array);
}
-#line 2318 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2341 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 381:
-#line 1334 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1334 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr l(new ListElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("option-data", l);
ctx.stack_.push_back(l);
ctx.enter(ctx.OPTION_DATA);
}
-#line 2329 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2352 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 382:
-#line 1339 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1339 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
ctx.leave();
}
-#line 2338 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2361 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 387:
-#line 1358 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1358 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->add(m);
ctx.stack_.push_back(m);
}
-#line 2348 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2371 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 388:
-#line 1362 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1362 "dhcp4_parser.yy" // lalr1.cc:907
{
/// @todo: the code or name parameters are required.
ctx.stack_.pop_back();
}
-#line 2357 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2380 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 389:
-#line 1370 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1370 "dhcp4_parser.yy" // lalr1.cc:907
{
// Parse the option-data list entry map
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.push_back(m);
}
-#line 2367 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2390 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 390:
-#line 1374 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1374 "dhcp4_parser.yy" // lalr1.cc:907
{
/// @todo: the code or name parameters are required.
// parsing completed
}
-#line 2376 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2399 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 405:
-#line 1407 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1407 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 2384 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2407 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 406:
-#line 1409 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1409 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr data(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("data", data);
ctx.leave();
}
-#line 2394 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2417 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 409:
-#line 1419 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1419 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr space(new BoolElement(yystack_[0].value.as< bool > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("csv-format", space);
}
-#line 2403 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2426 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 410:
-#line 1424 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1424 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr persist(new BoolElement(yystack_[0].value.as< bool > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("always-send", persist);
}
-#line 2412 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2435 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 411:
-#line 1432 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1432 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr l(new ListElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("pools", l);
ctx.stack_.push_back(l);
ctx.enter(ctx.POOLS);
}
-#line 2423 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2446 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 412:
-#line 1437 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1437 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
ctx.leave();
}
-#line 2432 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2455 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 417:
-#line 1452 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1452 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->add(m);
ctx.stack_.push_back(m);
}
-#line 2442 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2465 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 418:
-#line 1456 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1456 "dhcp4_parser.yy" // lalr1.cc:907
{
// The pool parameter is required.
ctx.require("pool", ctx.loc2pos(yystack_[3].location), ctx.loc2pos(yystack_[0].location));
ctx.stack_.pop_back();
}
-#line 2452 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2475 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 419:
-#line 1462 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1462 "dhcp4_parser.yy" // lalr1.cc:907
{
// Parse the pool list entry map
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.push_back(m);
}
-#line 2462 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2485 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 420:
-#line 1466 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1466 "dhcp4_parser.yy" // lalr1.cc:907
{
// The pool parameter is required.
ctx.require("pool", ctx.loc2pos(yystack_[3].location), ctx.loc2pos(yystack_[0].location));
// parsing completed
}
-#line 2472 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2495 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 430:
-#line 1485 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1485 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 2480 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2503 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 431:
-#line 1487 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1487 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr pool(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("pool", pool);
ctx.leave();
}
-#line 2490 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2513 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 432:
-#line 1493 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1493 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 2498 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2521 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 433:
-#line 1495 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1495 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr parent = ctx.stack_.back();
ElementPtr user_context = yystack_[0].value.as< ElementPtr > ();
parent->set("user-context", user_context);
ctx.leave();
}
-#line 2525 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2548 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 434:
-#line 1518 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1518 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 2533 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2556 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 435:
-#line 1520 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1520 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr parent = ctx.stack_.back();
ElementPtr user_context(new MapElement(ctx.loc2pos(yystack_[3].location)));
parent->set("user-context", user_context);
ctx.leave();
}
-#line 2562 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2585 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 436:
-#line 1548 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1548 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr l(new ListElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("reservations", l);
ctx.stack_.push_back(l);
ctx.enter(ctx.RESERVATIONS);
}
-#line 2573 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2596 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 437:
-#line 1553 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1553 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
ctx.leave();
}
-#line 2582 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2605 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 442:
-#line 1566 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1566 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->add(m);
ctx.stack_.push_back(m);
}
-#line 2592 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2615 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 443:
-#line 1570 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1570 "dhcp4_parser.yy" // lalr1.cc:907
{
/// @todo: an identifier parameter is required.
ctx.stack_.pop_back();
}
-#line 2601 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2624 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 444:
-#line 1575 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1575 "dhcp4_parser.yy" // lalr1.cc:907
{
// Parse the reservations list entry map
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.push_back(m);
}
-#line 2611 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2634 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 445:
-#line 1579 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1579 "dhcp4_parser.yy" // lalr1.cc:907
{
/// @todo: an identifier parameter is required.
// parsing completed
}
-#line 2620 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2643 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 465:
-#line 1610 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1610 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 2628 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2651 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 466:
-#line 1612 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1612 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr next_server(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("next-server", next_server);
ctx.leave();
}
-#line 2638 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2661 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 467:
-#line 1618 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1618 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 2646 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2669 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 468:
-#line 1620 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1620 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr srv(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("server-hostname", srv);
ctx.leave();
}
-#line 2656 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2679 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 469:
-#line 1626 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1626 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 2664 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2687 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 470:
-#line 1628 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1628 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr bootfile(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("boot-file-name", bootfile);
ctx.leave();
}
-#line 2674 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2697 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 471:
-#line 1634 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1634 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 2682 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2705 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 472:
-#line 1636 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1636 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr addr(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("ip-address", addr);
ctx.leave();
}
-#line 2692 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2715 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 473:
-#line 1642 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1642 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr l(new ListElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("ip-addresses", l);
ctx.stack_.push_back(l);
ctx.enter(ctx.NO_KEYWORD);
}
-#line 2703 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2726 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 474:
-#line 1647 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1647 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
ctx.leave();
}
-#line 2712 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2735 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 475:
-#line 1652 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1652 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 2720 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2743 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 476:
-#line 1654 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1654 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr d(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("duid", d);
ctx.leave();
}
-#line 2730 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2753 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 477:
-#line 1660 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1660 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 2738 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2761 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 478:
-#line 1662 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1662 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr hw(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("hw-address", hw);
ctx.leave();
}
-#line 2748 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2771 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 479:
-#line 1668 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1668 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 2756 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2779 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 480:
-#line 1670 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1670 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr hw(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("client-id", hw);
ctx.leave();
}
-#line 2766 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2789 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 481:
-#line 1676 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1676 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 2774 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2797 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 482:
-#line 1678 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1678 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr hw(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("circuit-id", hw);
ctx.leave();
}
-#line 2784 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2807 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 483:
-#line 1684 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1684 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 2792 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2815 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 484:
-#line 1686 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1686 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr hw(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("flex-id", hw);
ctx.leave();
}
-#line 2802 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2825 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 485:
-#line 1692 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1692 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 2810 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2833 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 486:
-#line 1694 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1694 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr host(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("hostname", host);
ctx.leave();
}
-#line 2820 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2843 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 487:
-#line 1700 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1700 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr c(new ListElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("client-classes", c);
ctx.stack_.push_back(c);
ctx.enter(ctx.NO_KEYWORD);
}
-#line 2831 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2854 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 488:
-#line 1705 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1705 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
ctx.leave();
}
-#line 2840 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2863 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 489:
-#line 1713 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1713 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("relay", m);
ctx.stack_.push_back(m);
ctx.enter(ctx.RELAY);
}
-#line 2851 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2874 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 490:
-#line 1718 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1718 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
ctx.leave();
}
-#line 2860 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2883 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 493:
-#line 1730 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1730 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr l(new ListElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("client-classes", l);
ctx.stack_.push_back(l);
ctx.enter(ctx.CLIENT_CLASSES);
}
-#line 2871 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2894 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 494:
-#line 1735 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1735 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
ctx.leave();
}
-#line 2880 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2903 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 497:
-#line 1744 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1744 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->add(m);
ctx.stack_.push_back(m);
}
-#line 2890 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2913 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 498:
-#line 1748 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1748 "dhcp4_parser.yy" // lalr1.cc:907
{
// The name client class parameter is required.
ctx.require("name", ctx.loc2pos(yystack_[3].location), ctx.loc2pos(yystack_[0].location));
ctx.stack_.pop_back();
}
-#line 2900 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2923 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 515:
-#line 1777 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1777 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 2908 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2931 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 516:
-#line 1779 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1779 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr test(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("test", test);
ctx.leave();
}
-#line 2918 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2941 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 517:
-#line 1785 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1785 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr b(new BoolElement(yystack_[0].value.as< bool > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("only-if-required", b);
}
-#line 2927 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2950 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 518:
-#line 1794 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1794 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr time(new IntElement(yystack_[0].value.as< int64_t > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("dhcp4o6-port", time);
}
-#line 2936 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2959 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 519:
-#line 1801 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1801 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("control-socket", m);
ctx.stack_.push_back(m);
ctx.enter(ctx.CONTROL_SOCKET);
}
-#line 2947 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2970 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 520:
-#line 1806 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1806 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
ctx.leave();
}
-#line 2956 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2979 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 528:
-#line 1822 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1822 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 2964 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2987 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 529:
-#line 1824 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1824 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr stype(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("socket-type", stype);
ctx.leave();
}
-#line 2974 "dhcp4_parser.cc" // lalr1.cc:856
+#line 2997 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 530:
-#line 1830 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1830 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 2982 "dhcp4_parser.cc" // lalr1.cc:856
+#line 3005 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 531:
-#line 1832 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1832 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr name(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("socket-name", name);
ctx.leave();
}
-#line 2992 "dhcp4_parser.cc" // lalr1.cc:856
+#line 3015 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 532:
-#line 1841 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1841 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 3000 "dhcp4_parser.cc" // lalr1.cc:856
+#line 3023 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 533:
-#line 1843 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1843 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr qc = yystack_[0].value.as< ElementPtr > ();
ctx.stack_.back()->set("dhcp-queue-control", qc);
ctx.leave();
}
-#line 3018 "dhcp4_parser.cc" // lalr1.cc:856
+#line 3041 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 534:
-#line 1859 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1859 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("dhcp-ddns", m);
ctx.stack_.push_back(m);
ctx.enter(ctx.DHCP_DDNS);
}
-#line 3029 "dhcp4_parser.cc" // lalr1.cc:856
+#line 3052 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 535:
-#line 1864 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1864 "dhcp4_parser.yy" // lalr1.cc:907
{
// The enable updates DHCP DDNS parameter is required.
ctx.require("enable-updates", ctx.loc2pos(yystack_[2].location), ctx.loc2pos(yystack_[0].location));
ctx.stack_.pop_back();
ctx.leave();
}
-#line 3040 "dhcp4_parser.cc" // lalr1.cc:856
+#line 3063 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 536:
-#line 1871 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1871 "dhcp4_parser.yy" // lalr1.cc:907
{
// Parse the dhcp-ddns map
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.push_back(m);
}
-#line 3050 "dhcp4_parser.cc" // lalr1.cc:856
+#line 3073 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 537:
-#line 1875 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1875 "dhcp4_parser.yy" // lalr1.cc:907
{
// The enable updates DHCP DDNS parameter is required.
ctx.require("enable-updates", ctx.loc2pos(yystack_[3].location), ctx.loc2pos(yystack_[0].location));
// parsing completed
}
-#line 3060 "dhcp4_parser.cc" // lalr1.cc:856
+#line 3083 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 559:
-#line 1906 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1906 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr b(new BoolElement(yystack_[0].value.as< bool > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("enable-updates", b);
}
-#line 3069 "dhcp4_parser.cc" // lalr1.cc:856
+#line 3092 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 560:
-#line 1911 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1911 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 3077 "dhcp4_parser.cc" // lalr1.cc:856
+#line 3100 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 561:
-#line 1913 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1913 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr s(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("qualifying-suffix", s);
ctx.leave();
}
-#line 3087 "dhcp4_parser.cc" // lalr1.cc:856
+#line 3110 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 562:
-#line 1919 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1919 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 3095 "dhcp4_parser.cc" // lalr1.cc:856
+#line 3118 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 563:
-#line 1921 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1921 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr s(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("server-ip", s);
ctx.leave();
}
-#line 3105 "dhcp4_parser.cc" // lalr1.cc:856
+#line 3128 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 564:
-#line 1927 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1927 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr i(new IntElement(yystack_[0].value.as< int64_t > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("server-port", i);
}
-#line 3114 "dhcp4_parser.cc" // lalr1.cc:856
+#line 3137 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 565:
-#line 1932 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1932 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 3122 "dhcp4_parser.cc" // lalr1.cc:856
+#line 3145 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 566:
-#line 1934 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1934 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr s(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("sender-ip", s);
ctx.leave();
}
-#line 3132 "dhcp4_parser.cc" // lalr1.cc:856
+#line 3155 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 567:
-#line 1940 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1940 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr i(new IntElement(yystack_[0].value.as< int64_t > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("sender-port", i);
}
-#line 3141 "dhcp4_parser.cc" // lalr1.cc:856
+#line 3164 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 568:
-#line 1945 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1945 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr i(new IntElement(yystack_[0].value.as< int64_t > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("max-queue-size", i);
}
-#line 3150 "dhcp4_parser.cc" // lalr1.cc:856
+#line 3173 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 569:
-#line 1950 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1950 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NCR_PROTOCOL);
}
-#line 3158 "dhcp4_parser.cc" // lalr1.cc:856
+#line 3181 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 570:
-#line 1952 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1952 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.stack_.back()->set("ncr-protocol", yystack_[0].value.as< ElementPtr > ());
ctx.leave();
}
-#line 3167 "dhcp4_parser.cc" // lalr1.cc:856
+#line 3190 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 571:
-#line 1958 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1958 "dhcp4_parser.yy" // lalr1.cc:907
{ yylhs.value.as< ElementPtr > () = ElementPtr(new StringElement("UDP", ctx.loc2pos(yystack_[0].location))); }
-#line 3173 "dhcp4_parser.cc" // lalr1.cc:856
+#line 3196 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 572:
-#line 1959 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1959 "dhcp4_parser.yy" // lalr1.cc:907
{ yylhs.value.as< ElementPtr > () = ElementPtr(new StringElement("TCP", ctx.loc2pos(yystack_[0].location))); }
-#line 3179 "dhcp4_parser.cc" // lalr1.cc:856
+#line 3202 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 573:
-#line 1962 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1962 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NCR_FORMAT);
}
-#line 3187 "dhcp4_parser.cc" // lalr1.cc:856
+#line 3210 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 574:
-#line 1964 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1964 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr json(new StringElement("JSON", ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("ncr-format", json);
ctx.leave();
}
-#line 3197 "dhcp4_parser.cc" // lalr1.cc:856
+#line 3220 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 575:
-#line 1970 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1970 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr b(new BoolElement(yystack_[0].value.as< bool > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("always-include-fqdn", b);
}
-#line 3206 "dhcp4_parser.cc" // lalr1.cc:856
+#line 3229 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 576:
-#line 1975 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1975 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr b(new BoolElement(yystack_[0].value.as< bool > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("override-no-update", b);
}
-#line 3215 "dhcp4_parser.cc" // lalr1.cc:856
+#line 3238 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 577:
-#line 1980 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1980 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr b(new BoolElement(yystack_[0].value.as< bool > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("override-client-update", b);
}
-#line 3224 "dhcp4_parser.cc" // lalr1.cc:856
+#line 3247 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 578:
-#line 1985 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1985 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.REPLACE_CLIENT_NAME);
}
-#line 3232 "dhcp4_parser.cc" // lalr1.cc:856
+#line 3255 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 579:
-#line 1987 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1987 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.stack_.back()->set("replace-client-name", yystack_[0].value.as< ElementPtr > ());
ctx.leave();
}
-#line 3241 "dhcp4_parser.cc" // lalr1.cc:856
+#line 3264 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 580:
-#line 1993 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1993 "dhcp4_parser.yy" // lalr1.cc:907
{
yylhs.value.as< ElementPtr > () = ElementPtr(new StringElement("when-present", ctx.loc2pos(yystack_[0].location)));
}
-#line 3249 "dhcp4_parser.cc" // lalr1.cc:856
+#line 3272 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 581:
-#line 1996 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1996 "dhcp4_parser.yy" // lalr1.cc:907
{
yylhs.value.as< ElementPtr > () = ElementPtr(new StringElement("never", ctx.loc2pos(yystack_[0].location)));
}
-#line 3257 "dhcp4_parser.cc" // lalr1.cc:856
+#line 3280 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 582:
-#line 1999 "dhcp4_parser.yy" // lalr1.cc:856
+#line 1999 "dhcp4_parser.yy" // lalr1.cc:907
{
yylhs.value.as< ElementPtr > () = ElementPtr(new StringElement("always", ctx.loc2pos(yystack_[0].location)));
}
-#line 3265 "dhcp4_parser.cc" // lalr1.cc:856
+#line 3288 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 583:
-#line 2002 "dhcp4_parser.yy" // lalr1.cc:856
+#line 2002 "dhcp4_parser.yy" // lalr1.cc:907
{
yylhs.value.as< ElementPtr > () = ElementPtr(new StringElement("when-not-present", ctx.loc2pos(yystack_[0].location)));
}
-#line 3273 "dhcp4_parser.cc" // lalr1.cc:856
+#line 3296 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 584:
-#line 2005 "dhcp4_parser.yy" // lalr1.cc:856
+#line 2005 "dhcp4_parser.yy" // lalr1.cc:907
{
error(yystack_[0].location, "boolean values for the replace-client-name are "
"no longer supported");
}
-#line 3282 "dhcp4_parser.cc" // lalr1.cc:856
+#line 3305 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 585:
-#line 2011 "dhcp4_parser.yy" // lalr1.cc:856
+#line 2011 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 3290 "dhcp4_parser.cc" // lalr1.cc:856
+#line 3313 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 586:
-#line 2013 "dhcp4_parser.yy" // lalr1.cc:856
+#line 2013 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr s(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("generated-prefix", s);
ctx.leave();
}
-#line 3300 "dhcp4_parser.cc" // lalr1.cc:856
+#line 3323 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 587:
-#line 2019 "dhcp4_parser.yy" // lalr1.cc:856
+#line 2019 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 3308 "dhcp4_parser.cc" // lalr1.cc:856
+#line 3331 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 588:
-#line 2021 "dhcp4_parser.yy" // lalr1.cc:856
+#line 2021 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr s(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("hostname-char-set", s);
ctx.leave();
}
-#line 3318 "dhcp4_parser.cc" // lalr1.cc:856
+#line 3341 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 589:
-#line 2027 "dhcp4_parser.yy" // lalr1.cc:856
+#line 2027 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 3326 "dhcp4_parser.cc" // lalr1.cc:856
+#line 3349 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 590:
-#line 2029 "dhcp4_parser.yy" // lalr1.cc:856
+#line 2029 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr s(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("hostname-char-replacement", s);
ctx.leave();
}
-#line 3336 "dhcp4_parser.cc" // lalr1.cc:856
+#line 3359 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 591:
-#line 2038 "dhcp4_parser.yy" // lalr1.cc:856
+#line 2038 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 3344 "dhcp4_parser.cc" // lalr1.cc:856
+#line 3367 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 592:
-#line 2040 "dhcp4_parser.yy" // lalr1.cc:856
+#line 2040 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.stack_.back()->set("Dhcp6", yystack_[0].value.as< ElementPtr > ());
ctx.leave();
}
-#line 3353 "dhcp4_parser.cc" // lalr1.cc:856
+#line 3376 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 593:
-#line 2045 "dhcp4_parser.yy" // lalr1.cc:856
+#line 2045 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 3361 "dhcp4_parser.cc" // lalr1.cc:856
+#line 3384 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 594:
-#line 2047 "dhcp4_parser.yy" // lalr1.cc:856
+#line 2047 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.stack_.back()->set("DhcpDdns", yystack_[0].value.as< ElementPtr > ());
ctx.leave();
}
-#line 3370 "dhcp4_parser.cc" // lalr1.cc:856
+#line 3393 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 595:
-#line 2052 "dhcp4_parser.yy" // lalr1.cc:856
+#line 2052 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 3378 "dhcp4_parser.cc" // lalr1.cc:856
+#line 3401 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 596:
-#line 2054 "dhcp4_parser.yy" // lalr1.cc:856
+#line 2054 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.stack_.back()->set("Control-agent", yystack_[0].value.as< ElementPtr > ());
ctx.leave();
}
-#line 3387 "dhcp4_parser.cc" // lalr1.cc:856
+#line 3410 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 597:
-#line 2059 "dhcp4_parser.yy" // lalr1.cc:856
+#line 2059 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->add(m);
ctx.stack_.push_back(m);
}
-#line 3397 "dhcp4_parser.cc" // lalr1.cc:856
+#line 3420 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 598:
-#line 2063 "dhcp4_parser.yy" // lalr1.cc:856
+#line 2063 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
}
-#line 3405 "dhcp4_parser.cc" // lalr1.cc:856
+#line 3428 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 599:
-#line 2068 "dhcp4_parser.yy" // lalr1.cc:856
+#line 2068 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr i(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("config-control", i);
ctx.stack_.push_back(i);
ctx.enter(ctx.CONFIG_CONTROL);
}
-#line 3416 "dhcp4_parser.cc" // lalr1.cc:856
+#line 3439 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 600:
-#line 2073 "dhcp4_parser.yy" // lalr1.cc:856
+#line 2073 "dhcp4_parser.yy" // lalr1.cc:907
{
// No config control params are required
ctx.stack_.pop_back();
ctx.leave();
}
-#line 3426 "dhcp4_parser.cc" // lalr1.cc:856
+#line 3449 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 601:
-#line 2079 "dhcp4_parser.yy" // lalr1.cc:856
+#line 2079 "dhcp4_parser.yy" // lalr1.cc:907
{
// Parse the config-control map
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.push_back(m);
}
-#line 3436 "dhcp4_parser.cc" // lalr1.cc:856
+#line 3459 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 602:
-#line 2083 "dhcp4_parser.yy" // lalr1.cc:856
+#line 2083 "dhcp4_parser.yy" // lalr1.cc:907
{
// No config_control params are required
// parsing completed
}
-#line 3445 "dhcp4_parser.cc" // lalr1.cc:856
+#line 3468 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 607:
-#line 2098 "dhcp4_parser.yy" // lalr1.cc:856
+#line 2098 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr l(new ListElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("config-databases", l);
ctx.stack_.push_back(l);
ctx.enter(ctx.CONFIG_DATABASE);
}
-#line 3456 "dhcp4_parser.cc" // lalr1.cc:856
+#line 3479 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 608:
-#line 2103 "dhcp4_parser.yy" // lalr1.cc:856
+#line 2103 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
ctx.leave();
}
-#line 3465 "dhcp4_parser.cc" // lalr1.cc:856
+#line 3488 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 609:
-#line 2113 "dhcp4_parser.yy" // lalr1.cc:856
+#line 2113 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("Logging", m);
ctx.stack_.push_back(m);
ctx.enter(ctx.LOGGING);
}
-#line 3476 "dhcp4_parser.cc" // lalr1.cc:856
+#line 3499 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 610:
-#line 2118 "dhcp4_parser.yy" // lalr1.cc:856
+#line 2118 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
ctx.leave();
}
-#line 3485 "dhcp4_parser.cc" // lalr1.cc:856
+#line 3508 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 611:
-#line 2123 "dhcp4_parser.yy" // lalr1.cc:856
+#line 2123 "dhcp4_parser.yy" // lalr1.cc:907
{
// Parse the Logging map
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.push_back(m);
}
-#line 3495 "dhcp4_parser.cc" // lalr1.cc:856
+#line 3518 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 612:
-#line 2127 "dhcp4_parser.yy" // lalr1.cc:856
+#line 2127 "dhcp4_parser.yy" // lalr1.cc:907
{
// parsing completed
}
-#line 3503 "dhcp4_parser.cc" // lalr1.cc:856
+#line 3526 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 616:
-#line 2143 "dhcp4_parser.yy" // lalr1.cc:856
+#line 2143 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr l(new ListElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("loggers", l);
ctx.stack_.push_back(l);
ctx.enter(ctx.LOGGERS);
}
-#line 3514 "dhcp4_parser.cc" // lalr1.cc:856
+#line 3537 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 617:
-#line 2148 "dhcp4_parser.yy" // lalr1.cc:856
+#line 2148 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
ctx.leave();
}
-#line 3523 "dhcp4_parser.cc" // lalr1.cc:856
+#line 3546 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 620:
-#line 2160 "dhcp4_parser.yy" // lalr1.cc:856
+#line 2160 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr l(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->add(l);
ctx.stack_.push_back(l);
}
-#line 3533 "dhcp4_parser.cc" // lalr1.cc:856
+#line 3556 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 621:
-#line 2164 "dhcp4_parser.yy" // lalr1.cc:856
+#line 2164 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
}
-#line 3541 "dhcp4_parser.cc" // lalr1.cc:856
+#line 3564 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 631:
-#line 2181 "dhcp4_parser.yy" // lalr1.cc:856
+#line 2181 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr dl(new IntElement(yystack_[0].value.as< int64_t > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("debuglevel", dl);
}
-#line 3550 "dhcp4_parser.cc" // lalr1.cc:856
+#line 3573 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 632:
-#line 2186 "dhcp4_parser.yy" // lalr1.cc:856
+#line 2186 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 3558 "dhcp4_parser.cc" // lalr1.cc:856
+#line 3581 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 633:
-#line 2188 "dhcp4_parser.yy" // lalr1.cc:856
+#line 2188 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr sev(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("severity", sev);
ctx.leave();
}
-#line 3568 "dhcp4_parser.cc" // lalr1.cc:856
+#line 3591 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 634:
-#line 2194 "dhcp4_parser.yy" // lalr1.cc:856
+#line 2194 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr l(new ListElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("output_options", l);
ctx.stack_.push_back(l);
ctx.enter(ctx.OUTPUT_OPTIONS);
}
-#line 3579 "dhcp4_parser.cc" // lalr1.cc:856
+#line 3602 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 635:
-#line 2199 "dhcp4_parser.yy" // lalr1.cc:856
+#line 2199 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
ctx.leave();
}
-#line 3588 "dhcp4_parser.cc" // lalr1.cc:856
+#line 3611 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 638:
-#line 2208 "dhcp4_parser.yy" // lalr1.cc:856
+#line 2208 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->add(m);
ctx.stack_.push_back(m);
}
-#line 3598 "dhcp4_parser.cc" // lalr1.cc:856
+#line 3621 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 639:
-#line 2212 "dhcp4_parser.yy" // lalr1.cc:856
+#line 2212 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
}
-#line 3606 "dhcp4_parser.cc" // lalr1.cc:856
+#line 3629 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 646:
-#line 2226 "dhcp4_parser.yy" // lalr1.cc:856
+#line 2226 "dhcp4_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 3614 "dhcp4_parser.cc" // lalr1.cc:856
+#line 3637 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 647:
-#line 2228 "dhcp4_parser.yy" // lalr1.cc:856
+#line 2228 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr sev(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("output", sev);
ctx.leave();
}
-#line 3624 "dhcp4_parser.cc" // lalr1.cc:856
+#line 3647 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 648:
-#line 2234 "dhcp4_parser.yy" // lalr1.cc:856
+#line 2234 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr flush(new BoolElement(yystack_[0].value.as< bool > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("flush", flush);
}
-#line 3633 "dhcp4_parser.cc" // lalr1.cc:856
+#line 3656 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 649:
-#line 2239 "dhcp4_parser.yy" // lalr1.cc:856
+#line 2239 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr maxsize(new IntElement(yystack_[0].value.as< int64_t > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("maxsize", maxsize);
}
-#line 3642 "dhcp4_parser.cc" // lalr1.cc:856
+#line 3665 "dhcp4_parser.cc" // lalr1.cc:907
break;
case 650:
-#line 2244 "dhcp4_parser.yy" // lalr1.cc:856
+#line 2244 "dhcp4_parser.yy" // lalr1.cc:907
{
ElementPtr maxver(new IntElement(yystack_[0].value.as< int64_t > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("maxver", maxver);
}
-#line 3651 "dhcp4_parser.cc" // lalr1.cc:856
+#line 3674 "dhcp4_parser.cc" // lalr1.cc:907
break;
-#line 3655 "dhcp4_parser.cc" // lalr1.cc:856
+#line 3678 "dhcp4_parser.cc" // lalr1.cc:907
default:
break;
}
}
+#if YY_EXCEPTIONS
catch (const syntax_error& yyexc)
{
error (yyexc);
YYERROR;
}
+#endif // YY_EXCEPTIONS
YY_SYMBOL_PRINT ("-> $$ =", yylhs);
yypop_ (yylen);
yylen = 0;
YY_STACK_PRINT ();
// Shift the result of the reduction.
- yypush_ (YY_NULLPTR, yylhs);
+ yypush_ (YY_NULLPTR, YY_MOVE (yylhs));
}
goto yynewstate;
// Shift the error token.
error_token.state = yyn;
- yypush_ ("Shifting", error_token);
+ yypush_ ("Shifting", YY_MOVE (error_token));
}
goto yynewstate;
return yyresult;
}
+#if YY_EXCEPTIONS
catch (...)
{
YYCDEBUG << "Exception caught: cleaning lookahead and stack\n";
// Do not try to display the values of the reclaimed symbols,
- // as their printer might throw an exception.
+ // as their printers might throw an exception.
if (!yyla.empty ())
yy_destroy_ (YY_NULLPTR, yyla);
}
throw;
}
+#endif // YY_EXCEPTIONS
}
void
}
- const short int Dhcp4Parser::yypact_ninf_ = -795;
+ const short Dhcp4Parser::yypact_ninf_ = -795;
const signed char Dhcp4Parser::yytable_ninf_ = -1;
- const short int
+ const short
Dhcp4Parser::yypact_[] =
{
428, -795, -795, -795, -795, -795, -795, -795, -795, -795,
-795, 589, -795, -795, -795, -795, -795
};
- const unsigned short int
+ const unsigned short
Dhcp4Parser::yydefact_[] =
{
0, 2, 4, 6, 8, 10, 12, 14, 16, 18,
639, 0, 648, 649, 650, 641, 647
};
- const short int
+ const short
Dhcp4Parser::yypgoto_[] =
{
-795, -795, -795, -795, -795, -795, -795, -795, -795, -795,
-795, -795, -795, -795, -795
};
- const short int
+ const short
Dhcp4Parser::yydefgoto_[] =
{
-1, 15, 16, 17, 18, 19, 20, 21, 22, 23,
1030, 1035, 1031, 1032, 1033
};
- const unsigned short int
+ const unsigned short
Dhcp4Parser::yytable_[] =
{
95, 136, 175, 195, 222, 239, 716, 265, 284, 301,
0, 0, 0, 906, 934
};
- const short int
+ const short
Dhcp4Parser::yycheck_[] =
{
70, 71, 72, 73, 74, 75, 596, 77, 78, 79,
-1, -1, -1, 989, 994
};
- const unsigned short int
+ const unsigned short
Dhcp4Parser::yystos_[] =
{
0, 152, 153, 154, 155, 156, 157, 158, 159, 160,
8, 4, 169, 167, 167, 539, 166
};
- const unsigned short int
+ const unsigned short
Dhcp4Parser::yyr1_[] =
{
0, 170, 172, 171, 173, 171, 174, 171, 175, 171,
};
#if PARSER4_DEBUG
- const unsigned short int
+ const unsigned short
Dhcp4Parser::yyrline_[] =
{
0, 255, 255, 255, 256, 256, 257, 257, 258, 258,
#endif // PARSER4_DEBUG
-#line 14 "dhcp4_parser.yy" // lalr1.cc:1163
+#line 14 "dhcp4_parser.yy" // lalr1.cc:1218
} } // isc::dhcp
-#line 4932 "dhcp4_parser.cc" // lalr1.cc:1163
-#line 2249 "dhcp4_parser.yy" // lalr1.cc:1164
+#line 4959 "dhcp4_parser.cc" // lalr1.cc:1218
+#line 2249 "dhcp4_parser.yy" // lalr1.cc:1219
void
-// A Bison parser, made by GNU Bison 3.0.5.
+// A Bison parser, made by GNU Bison 3.2.1.
// Skeleton interface for Bison LALR(1) parsers in C++
// This special exception was added by the Free Software Foundation in
// version 2.2 of Bison.
+
/**
** \file dhcp4_parser.h
** Define the isc::dhcp::parser class.
// C++ LALR(1) parser skeleton written by Akim Demaille.
+// Undocumented macros, especially those whose name start with YY_,
+// are private implementation details. Do not rely on them.
+
#ifndef YY_PARSER4_DHCP4_PARSER_H_INCLUDED
# define YY_PARSER4_DHCP4_PARSER_H_INCLUDED
// // "%code requires" blocks.
-#line 17 "dhcp4_parser.yy" // lalr1.cc:379
+#line 17 "dhcp4_parser.yy" // lalr1.cc:404
#include <string>
#include <cc/data.h>
using namespace isc::data;
using namespace std;
-#line 56 "dhcp4_parser.h" // lalr1.cc:379
+#line 60 "dhcp4_parser.h" // lalr1.cc:404
# include <cassert>
# include <cstdlib> // std::abort
# include <stdexcept>
# include <string>
# include <vector>
-# include "stack.hh"
+
+// Support move semantics when possible.
+#if defined __cplusplus && 201103L <= __cplusplus
+# define YY_MOVE std::move
+# define YY_MOVE_OR_COPY move
+# define YY_MOVE_REF(Type) Type&&
+# define YY_RVREF(Type) Type&&
+# define YY_COPY(Type) Type
+#else
+# define YY_MOVE
+# define YY_MOVE_OR_COPY copy
+# define YY_MOVE_REF(Type) Type&
+# define YY_RVREF(Type) const Type&
+# define YY_COPY(Type) const Type&
+#endif
# include "location.hh"
#include <typeinfo>
#ifndef YYASSERT
# define YY_ATTRIBUTE_UNUSED YY_ATTRIBUTE ((__unused__))
#endif
-#if !defined _Noreturn \
- && (!defined __STDC_VERSION__ || __STDC_VERSION__ < 201112)
-# if defined _MSC_VER && 1200 <= _MSC_VER
-# define _Noreturn __declspec (noreturn)
-# else
-# define _Noreturn YY_ATTRIBUTE ((__noreturn__))
-# endif
-#endif
-
/* Suppress unused-variable warnings by "using" E. */
#if ! defined lint || defined __GNUC__
# define YYUSE(E) ((void) (E))
# define YYUSE(E) /* empty */
#endif
-#if defined __GNUC__ && 407 <= __GNUC__ * 100 + __GNUC_MINOR__
+#if defined __GNUC__ && ! defined __ICC && 407 <= __GNUC__ * 100 + __GNUC_MINOR__
/* Suppress an incorrect diagnostic about yylval being uninitialized. */
# define YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN \
_Pragma ("GCC diagnostic push") \
# define YY_INITIAL_VALUE(Value) /* Nothing. */
#endif
+# ifndef YY_NULLPTR
+# if defined __cplusplus
+# if 201103L <= __cplusplus
+# define YY_NULLPTR nullptr
+# else
+# define YY_NULLPTR 0
+# endif
+# else
+# define YY_NULLPTR ((void*)0)
+# endif
+# endif
+
/* Debug traces. */
#ifndef PARSER4_DEBUG
# if defined YYDEBUG
# endif /* ! defined YYDEBUG */
#endif /* ! defined PARSER4_DEBUG */
-#line 14 "dhcp4_parser.yy" // lalr1.cc:379
+#line 14 "dhcp4_parser.yy" // lalr1.cc:404
namespace isc { namespace dhcp {
-#line 141 "dhcp4_parser.h" // lalr1.cc:379
+#line 162 "dhcp4_parser.h" // lalr1.cc:404
+
+ /// A stack with random access from its top.
+ template <typename T, typename S = std::vector<T> >
+ class stack
+ {
+ public:
+ // Hide our reversed order.
+ typedef typename S::reverse_iterator iterator;
+ typedef typename S::const_reverse_iterator const_iterator;
+ typedef typename S::size_type size_type;
+
+ stack (size_type n = 200)
+ : seq_ (n)
+ {}
+
+ /// Random access.
+ ///
+ /// Index 0 returns the topmost element.
+ T&
+ operator[] (size_type i)
+ {
+ return seq_[size () - 1 - i];
+ }
+
+ /// Random access.
+ ///
+ /// Index 0 returns the topmost element.
+ T&
+ operator[] (int i)
+ {
+ return operator[] (size_type (i));
+ }
+
+ /// Random access.
+ ///
+ /// Index 0 returns the topmost element.
+ const T&
+ operator[] (size_type i) const
+ {
+ return seq_[size () - 1 - i];
+ }
+
+ /// Random access.
+ ///
+ /// Index 0 returns the topmost element.
+ const T&
+ operator[] (int i) const
+ {
+ return operator[] (size_type (i));
+ }
+
+ /// Steal the contents of \a t.
+ ///
+ /// Close to move-semantics.
+ void
+ push (YY_MOVE_REF (T) t)
+ {
+ seq_.push_back (T ());
+ operator[](0).move (t);
+ }
+
+ void
+ pop (int n = 1)
+ {
+ for (; 0 < n; --n)
+ seq_.pop_back ();
+ }
+
+ void
+ clear ()
+ {
+ seq_.clear ();
+ }
+
+ size_type
+ size () const
+ {
+ return seq_.size ();
+ }
+
+ const_iterator
+ begin () const
+ {
+ return seq_.rbegin ();
+ }
+
+ const_iterator
+ end () const
+ {
+ return seq_.rend ();
+ }
+
+ private:
+ stack (const stack&);
+ stack& operator= (const stack&);
+ /// The wrapped container.
+ S seq_;
+ };
+
+ /// Present a slice of the top of a stack.
+ template <typename T, typename S = stack<T> >
+ class slice
+ {
+ public:
+ slice (const S& stack, int range)
+ : stack_ (stack)
+ , range_ (range)
+ {}
+
+ const T&
+ operator[] (int i) const
+ {
+ return stack_[range_ - i];
+ }
+
+ private:
+ const S& stack_;
+ int range_;
+ };
/// Empty construction.
variant ()
- : yytypeid_ (YY_NULLPTR)
+ : yybuffer_ ()
+ , yytypeid_ (YY_NULLPTR)
{}
/// Construct and fill.
template <typename T>
- variant (const T& t)
+ variant (YY_RVREF (T) t)
: yytypeid_ (&typeid (T))
{
YYASSERT (sizeof (T) <= S);
- new (yyas_<T> ()) T (t);
+ new (yyas_<T> ()) T (YY_MOVE (t));
}
/// Destruction, allowed only if empty.
/// Instantiate an empty \a T in here.
template <typename T>
T&
- build ()
+ emplace ()
{
YYASSERT (!yytypeid_);
YYASSERT (sizeof (T) <= S);
yytypeid_ = & typeid (T);
- return *new (yyas_<T> ()) T;
+ return *new (yyas_<T> ()) T ();
}
+# if defined __cplusplus && 201103L <= __cplusplus
+ /// Instantiate a \a T in here from \a t.
+ template <typename T, typename U>
+ T&
+ emplace (U&& u)
+ {
+ YYASSERT (!yytypeid_);
+ YYASSERT (sizeof (T) <= S);
+ yytypeid_ = & typeid (T);
+ return *new (yyas_<T> ()) T (std::forward <U>(u));
+ }
+# else
/// Instantiate a \a T in here from \a t.
template <typename T>
T&
- build (const T& t)
+ emplace (const T& t)
{
YYASSERT (!yytypeid_);
YYASSERT (sizeof (T) <= S);
yytypeid_ = & typeid (T);
return *new (yyas_<T> ()) T (t);
}
+# endif
+
+ /// Instantiate an empty \a T in here.
+ /// Obsolete, use emplace.
+ template <typename T>
+ T&
+ build ()
+ {
+ return emplace<T> ();
+ }
+
+ /// Instantiate a \a T in here from \a t.
+ /// Obsolete, use emplace.
+ template <typename T>
+ T&
+ build (const T& t)
+ {
+ return emplace<T> (t);
+ }
/// Accessor to a built \a T.
template <typename T>
T&
as ()
{
+ YYASSERT (yytypeid_);
YYASSERT (*yytypeid_ == typeid (T));
YYASSERT (sizeof (T) <= S);
return *yyas_<T> ();
const T&
as () const
{
+ YYASSERT (yytypeid_);
YYASSERT (*yytypeid_ == typeid (T));
YYASSERT (sizeof (T) <= S);
return *yyas_<T> ();
/// Both variants must be built beforehand, because swapping the actual
/// data requires reading it (with as()), and this is not possible on
/// unconstructed variants: it would require some dynamic testing, which
- /// should not be the variant's responsability.
+ /// should not be the variant's responsibility.
/// Swapping between built and (possibly) non-built is done with
/// variant::move ().
template <typename T>
void
move (self_type& other)
{
- build<T> ();
+# if defined __cplusplus && 201103L <= __cplusplus
+ emplace<T> (std::move (other.as<T> ()));
+# else
+ emplace<T> ();
swap<T> (other);
+# endif
other.destroy<T> ();
}
+# if defined __cplusplus && 201103L <= __cplusplus
+ /// Move the content of \a other to this.
+ template <typename T>
+ void
+ move (self_type&& other)
+ {
+ emplace<T> (std::move (other.as<T> ()));
+ other.destroy<T> ();
+ }
+#endif
+
/// Copy the content of \a other to this.
template <typename T>
void
copy (const self_type& other)
{
- build<T> (other.as<T> ());
+ emplace<T> (other.as<T> ());
}
/// Destroy the stored \a T.
private:
/// Prohibit blind copies.
- self_type& operator=(const self_type&);
+ self_type& operator= (const self_type&);
variant (const self_type&);
/// Accessor to raw memory as \a T.
// hr_mode
// ncr_protocol_value
// replace_client_name_value
- char dummy1[sizeof(ElementPtr)];
+ char dummy1[sizeof (ElementPtr)];
// "boolean"
- char dummy2[sizeof(bool)];
+ char dummy2[sizeof (bool)];
// "floating point"
- char dummy3[sizeof(double)];
+ char dummy3[sizeof (double)];
// "integer"
- char dummy4[sizeof(int64_t)];
+ char dummy4[sizeof (int64_t)];
// "constant string"
- char dummy5[sizeof(std::string)];
+ char dummy5[sizeof (std::string)];
};
/// Symbol semantic values.
- typedef variant<sizeof(union_type)> semantic_type;
+ typedef variant<sizeof (union_type)> semantic_type;
#else
typedef PARSER4_STYPE semantic_type;
#endif
/// A complete symbol.
///
/// Expects its Base type to provide access to the symbol type
- /// via type_get().
+ /// via type_get ().
///
/// Provide access to semantic value and location.
template <typename Base>
/// Default constructor.
basic_symbol ();
- /// Copy constructor.
- basic_symbol (const basic_symbol& other);
-
- /// Constructor for valueless symbols, and symbols from each type.
-
- basic_symbol (typename Base::kind_type t, const location_type& l);
-
- basic_symbol (typename Base::kind_type t, const ElementPtr v, const location_type& l);
+ /// Move or copy constructor.
+ basic_symbol (YY_RVREF (basic_symbol) other);
- basic_symbol (typename Base::kind_type t, const bool v, const location_type& l);
-
- basic_symbol (typename Base::kind_type t, const double v, const location_type& l);
-
- basic_symbol (typename Base::kind_type t, const int64_t v, const location_type& l);
-
- basic_symbol (typename Base::kind_type t, const std::string v, const location_type& l);
+ /// Constructor for valueless symbols, and symbols from each type.
+ basic_symbol (typename Base::kind_type t, YY_RVREF (location_type) l);
+ basic_symbol (typename Base::kind_type t, YY_RVREF (ElementPtr) v, YY_RVREF (location_type) l);
+ basic_symbol (typename Base::kind_type t, YY_RVREF (bool) v, YY_RVREF (location_type) l);
+ basic_symbol (typename Base::kind_type t, YY_RVREF (double) v, YY_RVREF (location_type) l);
+ basic_symbol (typename Base::kind_type t, YY_RVREF (int64_t) v, YY_RVREF (location_type) l);
+ basic_symbol (typename Base::kind_type t, YY_RVREF (std::string) v, YY_RVREF (location_type) l);
- /// Constructor for symbols with semantic value.
- basic_symbol (typename Base::kind_type t,
- const semantic_type& v,
- const location_type& l);
/// Destroy the symbol.
~basic_symbol ();
location_type location;
private:
+#if !defined __cplusplus || __cplusplus < 201103L
/// Assignment operator.
basic_symbol& operator= (const basic_symbol& other);
+#endif
};
/// Type access provider for token (enum) based symbols.
/// "External" symbols: returned by the scanner.
typedef basic_symbol<by_type> symbol_type;
+ /// Build a parser object.
+ Dhcp4Parser (isc::dhcp::Parser4Context& ctx_yyarg);
+ virtual ~Dhcp4Parser ();
+
+ /// Parse. An alias for parse ().
+ /// \returns 0 iff parsing succeeded.
+ int operator() ();
+
+ /// Parse.
+ /// \returns 0 iff parsing succeeded.
+ virtual int parse ();
+
+#if PARSER4_DEBUG
+ /// The current debugging stream.
+ std::ostream& debug_stream () const YY_ATTRIBUTE_PURE;
+ /// Set the current debugging stream.
+ void set_debug_stream (std::ostream &);
+
+ /// Type for debugging levels.
+ typedef int debug_level_type;
+ /// The current debugging level.
+ debug_level_type debug_level () const YY_ATTRIBUTE_PURE;
+ /// Set the current debugging level.
+ void set_debug_level (debug_level_type l);
+#endif
+
+ /// Report a syntax error.
+ /// \param loc where the syntax error is found.
+ /// \param msg a description of the syntax error.
+ virtual void error (const location_type& loc, const std::string& msg);
+
+ /// Report a syntax error.
+ void error (const syntax_error& err);
+
// Symbol constructors declarations.
- static inline
+ static
symbol_type
- make_END (const location_type& l);
+ make_END (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_COMMA (const location_type& l);
+ make_COMMA (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_COLON (const location_type& l);
+ make_COLON (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_LSQUARE_BRACKET (const location_type& l);
+ make_LSQUARE_BRACKET (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_RSQUARE_BRACKET (const location_type& l);
+ make_RSQUARE_BRACKET (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_LCURLY_BRACKET (const location_type& l);
+ make_LCURLY_BRACKET (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_RCURLY_BRACKET (const location_type& l);
+ make_RCURLY_BRACKET (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_NULL_TYPE (const location_type& l);
+ make_NULL_TYPE (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_DHCP4 (const location_type& l);
+ make_DHCP4 (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_CONFIG_CONTROL (const location_type& l);
+ make_CONFIG_CONTROL (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_CONFIG_DATABASES (const location_type& l);
+ make_CONFIG_DATABASES (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_INTERFACES_CONFIG (const location_type& l);
+ make_INTERFACES_CONFIG (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_INTERFACES (const location_type& l);
+ make_INTERFACES (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_DHCP_SOCKET_TYPE (const location_type& l);
+ make_DHCP_SOCKET_TYPE (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_RAW (const location_type& l);
+ make_RAW (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_UDP (const location_type& l);
+ make_UDP (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_OUTBOUND_INTERFACE (const location_type& l);
+ make_OUTBOUND_INTERFACE (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_SAME_AS_INBOUND (const location_type& l);
+ make_SAME_AS_INBOUND (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_USE_ROUTING (const location_type& l);
+ make_USE_ROUTING (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_RE_DETECT (const location_type& l);
+ make_RE_DETECT (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_SANITY_CHECKS (const location_type& l);
+ make_SANITY_CHECKS (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_LEASE_CHECKS (const location_type& l);
+ make_LEASE_CHECKS (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_ECHO_CLIENT_ID (const location_type& l);
+ make_ECHO_CLIENT_ID (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_MATCH_CLIENT_ID (const location_type& l);
+ make_MATCH_CLIENT_ID (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_AUTHORITATIVE (const location_type& l);
+ make_AUTHORITATIVE (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_NEXT_SERVER (const location_type& l);
+ make_NEXT_SERVER (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_SERVER_HOSTNAME (const location_type& l);
+ make_SERVER_HOSTNAME (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_BOOT_FILE_NAME (const location_type& l);
+ make_BOOT_FILE_NAME (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_LEASE_DATABASE (const location_type& l);
+ make_LEASE_DATABASE (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_HOSTS_DATABASE (const location_type& l);
+ make_HOSTS_DATABASE (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_HOSTS_DATABASES (const location_type& l);
+ make_HOSTS_DATABASES (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_TYPE (const location_type& l);
+ make_TYPE (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_MEMFILE (const location_type& l);
+ make_MEMFILE (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_MYSQL (const location_type& l);
+ make_MYSQL (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_POSTGRESQL (const location_type& l);
+ make_POSTGRESQL (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_CQL (const location_type& l);
+ make_CQL (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_USER (const location_type& l);
+ make_USER (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_PASSWORD (const location_type& l);
+ make_PASSWORD (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_HOST (const location_type& l);
+ make_HOST (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_PORT (const location_type& l);
+ make_PORT (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_PERSIST (const location_type& l);
+ make_PERSIST (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_LFC_INTERVAL (const location_type& l);
+ make_LFC_INTERVAL (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_READONLY (const location_type& l);
+ make_READONLY (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_CONNECT_TIMEOUT (const location_type& l);
+ make_CONNECT_TIMEOUT (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_CONTACT_POINTS (const location_type& l);
+ make_CONTACT_POINTS (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_KEYSPACE (const location_type& l);
+ make_KEYSPACE (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_MAX_RECONNECT_TRIES (const location_type& l);
+ make_MAX_RECONNECT_TRIES (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_RECONNECT_WAIT_TIME (const location_type& l);
+ make_RECONNECT_WAIT_TIME (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_REQUEST_TIMEOUT (const location_type& l);
+ make_REQUEST_TIMEOUT (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_TCP_KEEPALIVE (const location_type& l);
+ make_TCP_KEEPALIVE (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_TCP_NODELAY (const location_type& l);
+ make_TCP_NODELAY (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_VALID_LIFETIME (const location_type& l);
+ make_VALID_LIFETIME (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_RENEW_TIMER (const location_type& l);
+ make_RENEW_TIMER (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_REBIND_TIMER (const location_type& l);
+ make_REBIND_TIMER (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_DECLINE_PROBATION_PERIOD (const location_type& l);
+ make_DECLINE_PROBATION_PERIOD (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_SERVER_TAG (const location_type& l);
+ make_SERVER_TAG (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_SUBNET4 (const location_type& l);
+ make_SUBNET4 (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_SUBNET_4O6_INTERFACE (const location_type& l);
+ make_SUBNET_4O6_INTERFACE (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_SUBNET_4O6_INTERFACE_ID (const location_type& l);
+ make_SUBNET_4O6_INTERFACE_ID (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_SUBNET_4O6_SUBNET (const location_type& l);
+ make_SUBNET_4O6_SUBNET (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_OPTION_DEF (const location_type& l);
+ make_OPTION_DEF (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_OPTION_DATA (const location_type& l);
+ make_OPTION_DATA (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_NAME (const location_type& l);
+ make_NAME (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_DATA (const location_type& l);
+ make_DATA (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_CODE (const location_type& l);
+ make_CODE (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_SPACE (const location_type& l);
+ make_SPACE (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_CSV_FORMAT (const location_type& l);
+ make_CSV_FORMAT (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_ALWAYS_SEND (const location_type& l);
+ make_ALWAYS_SEND (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_RECORD_TYPES (const location_type& l);
+ make_RECORD_TYPES (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_ENCAPSULATE (const location_type& l);
+ make_ENCAPSULATE (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_ARRAY (const location_type& l);
+ make_ARRAY (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_SHARED_NETWORKS (const location_type& l);
+ make_SHARED_NETWORKS (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_POOLS (const location_type& l);
+ make_POOLS (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_POOL (const location_type& l);
+ make_POOL (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_USER_CONTEXT (const location_type& l);
+ make_USER_CONTEXT (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_COMMENT (const location_type& l);
+ make_COMMENT (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_SUBNET (const location_type& l);
+ make_SUBNET (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_INTERFACE (const location_type& l);
+ make_INTERFACE (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_ID (const location_type& l);
+ make_ID (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_RESERVATION_MODE (const location_type& l);
+ make_RESERVATION_MODE (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_DISABLED (const location_type& l);
+ make_DISABLED (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_OUT_OF_POOL (const location_type& l);
+ make_OUT_OF_POOL (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_GLOBAL (const location_type& l);
+ make_GLOBAL (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_ALL (const location_type& l);
+ make_ALL (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_HOST_RESERVATION_IDENTIFIERS (const location_type& l);
+ make_HOST_RESERVATION_IDENTIFIERS (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_CLIENT_CLASSES (const location_type& l);
+ make_CLIENT_CLASSES (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_REQUIRE_CLIENT_CLASSES (const location_type& l);
+ make_REQUIRE_CLIENT_CLASSES (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_TEST (const location_type& l);
+ make_TEST (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_ONLY_IF_REQUIRED (const location_type& l);
+ make_ONLY_IF_REQUIRED (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_CLIENT_CLASS (const location_type& l);
+ make_CLIENT_CLASS (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_RESERVATIONS (const location_type& l);
+ make_RESERVATIONS (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_DUID (const location_type& l);
+ make_DUID (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_HW_ADDRESS (const location_type& l);
+ make_HW_ADDRESS (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_CIRCUIT_ID (const location_type& l);
+ make_CIRCUIT_ID (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_CLIENT_ID (const location_type& l);
+ make_CLIENT_ID (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_HOSTNAME (const location_type& l);
+ make_HOSTNAME (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_FLEX_ID (const location_type& l);
+ make_FLEX_ID (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_RELAY (const location_type& l);
+ make_RELAY (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_IP_ADDRESS (const location_type& l);
+ make_IP_ADDRESS (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_IP_ADDRESSES (const location_type& l);
+ make_IP_ADDRESSES (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_HOOKS_LIBRARIES (const location_type& l);
+ make_HOOKS_LIBRARIES (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_LIBRARY (const location_type& l);
+ make_LIBRARY (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_PARAMETERS (const location_type& l);
+ make_PARAMETERS (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_EXPIRED_LEASES_PROCESSING (const location_type& l);
+ make_EXPIRED_LEASES_PROCESSING (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_RECLAIM_TIMER_WAIT_TIME (const location_type& l);
+ make_RECLAIM_TIMER_WAIT_TIME (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_FLUSH_RECLAIMED_TIMER_WAIT_TIME (const location_type& l);
+ make_FLUSH_RECLAIMED_TIMER_WAIT_TIME (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_HOLD_RECLAIMED_TIME (const location_type& l);
+ make_HOLD_RECLAIMED_TIME (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_MAX_RECLAIM_LEASES (const location_type& l);
+ make_MAX_RECLAIM_LEASES (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_MAX_RECLAIM_TIME (const location_type& l);
+ make_MAX_RECLAIM_TIME (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_UNWARNED_RECLAIM_CYCLES (const location_type& l);
+ make_UNWARNED_RECLAIM_CYCLES (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_DHCP4O6_PORT (const location_type& l);
+ make_DHCP4O6_PORT (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_CONTROL_SOCKET (const location_type& l);
+ make_CONTROL_SOCKET (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_SOCKET_TYPE (const location_type& l);
+ make_SOCKET_TYPE (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_SOCKET_NAME (const location_type& l);
+ make_SOCKET_NAME (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_DHCP_QUEUE_CONTROL (const location_type& l);
+ make_DHCP_QUEUE_CONTROL (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_DHCP_DDNS (const location_type& l);
+ make_DHCP_DDNS (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_ENABLE_UPDATES (const location_type& l);
+ make_ENABLE_UPDATES (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_QUALIFYING_SUFFIX (const location_type& l);
+ make_QUALIFYING_SUFFIX (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_SERVER_IP (const location_type& l);
+ make_SERVER_IP (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_SERVER_PORT (const location_type& l);
+ make_SERVER_PORT (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_SENDER_IP (const location_type& l);
+ make_SENDER_IP (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_SENDER_PORT (const location_type& l);
+ make_SENDER_PORT (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_MAX_QUEUE_SIZE (const location_type& l);
+ make_MAX_QUEUE_SIZE (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_NCR_PROTOCOL (const location_type& l);
+ make_NCR_PROTOCOL (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_NCR_FORMAT (const location_type& l);
+ make_NCR_FORMAT (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_ALWAYS_INCLUDE_FQDN (const location_type& l);
+ make_ALWAYS_INCLUDE_FQDN (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_OVERRIDE_NO_UPDATE (const location_type& l);
+ make_OVERRIDE_NO_UPDATE (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_OVERRIDE_CLIENT_UPDATE (const location_type& l);
+ make_OVERRIDE_CLIENT_UPDATE (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_REPLACE_CLIENT_NAME (const location_type& l);
+ make_REPLACE_CLIENT_NAME (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_GENERATED_PREFIX (const location_type& l);
+ make_GENERATED_PREFIX (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_TCP (const location_type& l);
+ make_TCP (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_JSON (const location_type& l);
+ make_JSON (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_WHEN_PRESENT (const location_type& l);
+ make_WHEN_PRESENT (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_NEVER (const location_type& l);
+ make_NEVER (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_ALWAYS (const location_type& l);
+ make_ALWAYS (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_WHEN_NOT_PRESENT (const location_type& l);
+ make_WHEN_NOT_PRESENT (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_HOSTNAME_CHAR_SET (const location_type& l);
+ make_HOSTNAME_CHAR_SET (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_HOSTNAME_CHAR_REPLACEMENT (const location_type& l);
+ make_HOSTNAME_CHAR_REPLACEMENT (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_LOGGING (const location_type& l);
+ make_LOGGING (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_LOGGERS (const location_type& l);
+ make_LOGGERS (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_OUTPUT_OPTIONS (const location_type& l);
+ make_OUTPUT_OPTIONS (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_OUTPUT (const location_type& l);
+ make_OUTPUT (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_DEBUGLEVEL (const location_type& l);
+ make_DEBUGLEVEL (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_SEVERITY (const location_type& l);
+ make_SEVERITY (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_FLUSH (const location_type& l);
+ make_FLUSH (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_MAXSIZE (const location_type& l);
+ make_MAXSIZE (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_MAXVER (const location_type& l);
+ make_MAXVER (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_DHCP6 (const location_type& l);
+ make_DHCP6 (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_DHCPDDNS (const location_type& l);
+ make_DHCPDDNS (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_CONTROL_AGENT (const location_type& l);
+ make_CONTROL_AGENT (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_TOPLEVEL_JSON (const location_type& l);
+ make_TOPLEVEL_JSON (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_TOPLEVEL_DHCP4 (const location_type& l);
+ make_TOPLEVEL_DHCP4 (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_SUB_DHCP4 (const location_type& l);
+ make_SUB_DHCP4 (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_SUB_INTERFACES4 (const location_type& l);
+ make_SUB_INTERFACES4 (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_SUB_SUBNET4 (const location_type& l);
+ make_SUB_SUBNET4 (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_SUB_POOL4 (const location_type& l);
+ make_SUB_POOL4 (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_SUB_RESERVATION (const location_type& l);
+ make_SUB_RESERVATION (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_SUB_OPTION_DEFS (const location_type& l);
+ make_SUB_OPTION_DEFS (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_SUB_OPTION_DEF (const location_type& l);
+ make_SUB_OPTION_DEF (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_SUB_OPTION_DATA (const location_type& l);
+ make_SUB_OPTION_DATA (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_SUB_HOOKS_LIBRARY (const location_type& l);
+ make_SUB_HOOKS_LIBRARY (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_SUB_DHCP_DDNS (const location_type& l);
+ make_SUB_DHCP_DDNS (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_SUB_LOGGING (const location_type& l);
+ make_SUB_LOGGING (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_SUB_CONFIG_CONTROL (const location_type& l);
+ make_SUB_CONFIG_CONTROL (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_STRING (const std::string& v, const location_type& l);
+ make_STRING (YY_COPY (std::string) v, YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_INTEGER (const int64_t& v, const location_type& l);
+ make_INTEGER (YY_COPY (int64_t) v, YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_FLOAT (const double& v, const location_type& l);
+ make_FLOAT (YY_COPY (double) v, YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_BOOLEAN (const bool& v, const location_type& l);
-
-
- /// Build a parser object.
- Dhcp4Parser (isc::dhcp::Parser4Context& ctx_yyarg);
- virtual ~Dhcp4Parser ();
-
- /// Parse.
- /// \returns 0 iff parsing succeeded.
- virtual int parse ();
-
-#if PARSER4_DEBUG
- /// The current debugging stream.
- std::ostream& debug_stream () const YY_ATTRIBUTE_PURE;
- /// Set the current debugging stream.
- void set_debug_stream (std::ostream &);
-
- /// Type for debugging levels.
- typedef int debug_level_type;
- /// The current debugging level.
- debug_level_type debug_level () const YY_ATTRIBUTE_PURE;
- /// Set the current debugging level.
- void set_debug_level (debug_level_type l);
-#endif
+ make_BOOLEAN (YY_COPY (bool) v, YY_COPY (location_type) l);
- /// Report a syntax error.
- /// \param loc where the syntax error is found.
- /// \param msg a description of the syntax error.
- virtual void error (const location_type& loc, const std::string& msg);
- /// Report a syntax error.
- void error (const syntax_error& err);
private:
/// This class is not copyable.
/// \param yyvalue the value to check
static bool yy_table_value_is_error_ (int yyvalue);
- static const short int yypact_ninf_;
+ static const short yypact_ninf_;
static const signed char yytable_ninf_;
/// Convert a scanner token number \a t to a symbol number.
// Tables.
// YYPACT[STATE-NUM] -- Index in YYTABLE of the portion describing
// STATE-NUM.
- static const short int yypact_[];
+ static const short yypact_[];
// YYDEFACT[STATE-NUM] -- Default reduction number in state STATE-NUM.
// Performed when YYTABLE does not specify something else to do. Zero
// means the default is an error.
- static const unsigned short int yydefact_[];
+ static const unsigned short yydefact_[];
// YYPGOTO[NTERM-NUM].
- static const short int yypgoto_[];
+ static const short yypgoto_[];
// YYDEFGOTO[NTERM-NUM].
- static const short int yydefgoto_[];
+ static const short yydefgoto_[];
// YYTABLE[YYPACT[STATE-NUM]] -- What to do in state STATE-NUM. If
// positive, shift that token. If negative, reduce the rule whose
// number is the opposite. If YYTABLE_NINF, syntax error.
- static const unsigned short int yytable_[];
+ static const unsigned short yytable_[];
- static const short int yycheck_[];
+ static const short yycheck_[];
// YYSTOS[STATE-NUM] -- The (internal number of the) accessing
// symbol of state STATE-NUM.
- static const unsigned short int yystos_[];
+ static const unsigned short yystos_[];
// YYR1[YYN] -- Symbol number of symbol that rule YYN derives.
- static const unsigned short int yyr1_[];
+ static const unsigned short yyr1_[];
// YYR2[YYN] -- Number of symbols on the right hand side of rule YYN.
static const unsigned char yyr2_[];
static const char* const yytname_[];
#if PARSER4_DEBUG
// YYRLINE[YYN] -- Source line where rule number YYN was defined.
- static const unsigned short int yyrline_[];
+ static const unsigned short yyrline_[];
/// Report on the debug stream that the rule \a r is going to be reduced.
virtual void yy_reduce_print_ (int r);
/// Print the state stack on the debug stream.
virtual void yystack_print_ ();
- // Debugging.
+ /// Debugging level.
int yydebug_;
+ /// Debug stream.
std::ostream* yycdebug_;
/// \brief Display a symbol type, value and location.
typedef basic_symbol<by_state> super_type;
/// Construct an empty symbol.
stack_symbol_type ();
- /// Copy construct.
- stack_symbol_type (const stack_symbol_type& that);
+ /// Move or copy construction.
+ stack_symbol_type (YY_RVREF (stack_symbol_type) that);
/// Steal the contents from \a sym to build this.
- stack_symbol_type (state_type s, symbol_type& sym);
- /// Assignment, needed by push_back.
- stack_symbol_type& operator= (const stack_symbol_type& that);
+ stack_symbol_type (state_type s, YY_MOVE_REF (symbol_type) sym);
+#if !defined __cplusplus || __cplusplus < 201103L
+ /// Assignment, needed by push_back by some old implementations.
+ /// Moves the contents of that.
+ stack_symbol_type& operator= (stack_symbol_type& that);
+#endif
};
/// Stack type.
/// Push a new state on the stack.
/// \param m a debug message to display
/// if null, no trace is output.
- /// \param s the symbol
+ /// \param sym the symbol
/// \warning the contents of \a s.value is stolen.
- void yypush_ (const char* m, stack_symbol_type& s);
+ void yypush_ (const char* m, YY_MOVE_REF (stack_symbol_type) sym);
/// Push a new look ahead token on the state on the stack.
/// \param m a debug message to display
/// if null, no trace is output.
/// \param s the state
/// \param sym the symbol (for its value and location).
- /// \warning the contents of \a s.value is stolen.
- void yypush_ (const char* m, state_type s, symbol_type& sym);
+ /// \warning the contents of \a sym.value is stolen.
+ void yypush_ (const char* m, state_type s, YY_MOVE_REF (symbol_type) sym);
- /// Pop \a n symbols the three stacks.
- void yypop_ (unsigned n = 1);
+ /// Pop \a n symbols from the stack.
+ void yypop_ (int n = 1);
/// Constants.
enum
template <typename Base>
Dhcp4Parser::basic_symbol<Base>::basic_symbol ()
: value ()
+ , location ()
{}
template <typename Base>
- Dhcp4Parser::basic_symbol<Base>::basic_symbol (const basic_symbol& other)
- : Base (other)
+ Dhcp4Parser::basic_symbol<Base>::basic_symbol (YY_RVREF (basic_symbol) other)
+ : Base (YY_MOVE (other))
, value ()
- , location (other.location)
+ , location (YY_MOVE (other.location))
{
switch (other.type_get ())
{
case 338: // hr_mode
case 487: // ncr_protocol_value
case 495: // replace_client_name_value
- value.copy< ElementPtr > (other.value);
+ value.YY_MOVE_OR_COPY< ElementPtr > (YY_MOVE (other.value));
break;
case 169: // "boolean"
- value.copy< bool > (other.value);
+ value.YY_MOVE_OR_COPY< bool > (YY_MOVE (other.value));
break;
case 168: // "floating point"
- value.copy< double > (other.value);
+ value.YY_MOVE_OR_COPY< double > (YY_MOVE (other.value));
break;
case 167: // "integer"
- value.copy< int64_t > (other.value);
+ value.YY_MOVE_OR_COPY< int64_t > (YY_MOVE (other.value));
break;
case 166: // "constant string"
- value.copy< std::string > (other.value);
+ value.YY_MOVE_OR_COPY< std::string > (YY_MOVE (other.value));
break;
default:
}
- template <typename Base>
- Dhcp4Parser::basic_symbol<Base>::basic_symbol (typename Base::kind_type t, const semantic_type& v, const location_type& l)
- : Base (t)
- , value ()
- , location (l)
- {
- (void) v;
- switch (this->type_get ())
- {
- case 186: // value
- case 190: // map_value
- case 231: // socket_type
- case 234: // outbound_interface_value
- case 256: // db_type
- case 338: // hr_mode
- case 487: // ncr_protocol_value
- case 495: // replace_client_name_value
- value.copy< ElementPtr > (v);
- break;
-
- case 169: // "boolean"
- value.copy< bool > (v);
- break;
-
- case 168: // "floating point"
- value.copy< double > (v);
- break;
-
- case 167: // "integer"
- value.copy< int64_t > (v);
- break;
-
- case 166: // "constant string"
- value.copy< std::string > (v);
- break;
-
- default:
- break;
- }
-}
-
// Implementation of basic_symbol constructor for each type.
-
template <typename Base>
- Dhcp4Parser::basic_symbol<Base>::basic_symbol (typename Base::kind_type t, const location_type& l)
+ Dhcp4Parser::basic_symbol<Base>::basic_symbol (typename Base::kind_type t, YY_RVREF (location_type) l)
: Base (t)
- , value ()
- , location (l)
+ , location (YY_MOVE (l))
{}
template <typename Base>
- Dhcp4Parser::basic_symbol<Base>::basic_symbol (typename Base::kind_type t, const ElementPtr v, const location_type& l)
+ Dhcp4Parser::basic_symbol<Base>::basic_symbol (typename Base::kind_type t, YY_RVREF (ElementPtr) v, YY_RVREF (location_type) l)
: Base (t)
- , value (v)
- , location (l)
+ , value (YY_MOVE (v))
+ , location (YY_MOVE (l))
{}
template <typename Base>
- Dhcp4Parser::basic_symbol<Base>::basic_symbol (typename Base::kind_type t, const bool v, const location_type& l)
+ Dhcp4Parser::basic_symbol<Base>::basic_symbol (typename Base::kind_type t, YY_RVREF (bool) v, YY_RVREF (location_type) l)
: Base (t)
- , value (v)
- , location (l)
+ , value (YY_MOVE (v))
+ , location (YY_MOVE (l))
{}
template <typename Base>
- Dhcp4Parser::basic_symbol<Base>::basic_symbol (typename Base::kind_type t, const double v, const location_type& l)
+ Dhcp4Parser::basic_symbol<Base>::basic_symbol (typename Base::kind_type t, YY_RVREF (double) v, YY_RVREF (location_type) l)
: Base (t)
- , value (v)
- , location (l)
+ , value (YY_MOVE (v))
+ , location (YY_MOVE (l))
{}
template <typename Base>
- Dhcp4Parser::basic_symbol<Base>::basic_symbol (typename Base::kind_type t, const int64_t v, const location_type& l)
+ Dhcp4Parser::basic_symbol<Base>::basic_symbol (typename Base::kind_type t, YY_RVREF (int64_t) v, YY_RVREF (location_type) l)
: Base (t)
- , value (v)
- , location (l)
+ , value (YY_MOVE (v))
+ , location (YY_MOVE (l))
{}
template <typename Base>
- Dhcp4Parser::basic_symbol<Base>::basic_symbol (typename Base::kind_type t, const std::string v, const location_type& l)
+ Dhcp4Parser::basic_symbol<Base>::basic_symbol (typename Base::kind_type t, YY_RVREF (std::string) v, YY_RVREF (location_type) l)
: Base (t)
- , value (v)
- , location (l)
+ , value (YY_MOVE (v))
+ , location (YY_MOVE (l))
{}
+
template <typename Base>
Dhcp4Parser::basic_symbol<Base>::~basic_symbol ()
{
case 338: // hr_mode
case 487: // ncr_protocol_value
case 495: // replace_client_name_value
- value.move< ElementPtr > (s.value);
+ value.move< ElementPtr > (YY_MOVE (s.value));
break;
case 169: // "boolean"
- value.move< bool > (s.value);
+ value.move< bool > (YY_MOVE (s.value));
break;
case 168: // "floating point"
- value.move< double > (s.value);
+ value.move< double > (YY_MOVE (s.value));
break;
case 167: // "integer"
- value.move< int64_t > (s.value);
+ value.move< int64_t > (YY_MOVE (s.value));
break;
case 166: // "constant string"
- value.move< std::string > (s.value);
+ value.move< std::string > (YY_MOVE (s.value));
break;
default:
break;
}
- location = s.location;
+ location = YY_MOVE (s.location);
}
// by_type.
// YYTOKNUM[NUM] -- (External) token number corresponding to the
// (internal) symbol number NUM (which must be that of a token). */
static
- const unsigned short int
+ const unsigned short
yytoken_number_[] =
{
0, 256, 257, 258, 259, 260, 261, 262, 263, 264,
};
return static_cast<token_type> (yytoken_number_[type]);
}
+
// Implementation of make_symbol for each symbol type.
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_END (const location_type& l)
+ Dhcp4Parser::make_END (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_END, l);
+ return symbol_type (token::TOKEN_END, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_COMMA (const location_type& l)
+ Dhcp4Parser::make_COMMA (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_COMMA, l);
+ return symbol_type (token::TOKEN_COMMA, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_COLON (const location_type& l)
+ Dhcp4Parser::make_COLON (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_COLON, l);
+ return symbol_type (token::TOKEN_COLON, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_LSQUARE_BRACKET (const location_type& l)
+ Dhcp4Parser::make_LSQUARE_BRACKET (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_LSQUARE_BRACKET, l);
+ return symbol_type (token::TOKEN_LSQUARE_BRACKET, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_RSQUARE_BRACKET (const location_type& l)
+ Dhcp4Parser::make_RSQUARE_BRACKET (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_RSQUARE_BRACKET, l);
+ return symbol_type (token::TOKEN_RSQUARE_BRACKET, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_LCURLY_BRACKET (const location_type& l)
+ Dhcp4Parser::make_LCURLY_BRACKET (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_LCURLY_BRACKET, l);
+ return symbol_type (token::TOKEN_LCURLY_BRACKET, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_RCURLY_BRACKET (const location_type& l)
+ Dhcp4Parser::make_RCURLY_BRACKET (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_RCURLY_BRACKET, l);
+ return symbol_type (token::TOKEN_RCURLY_BRACKET, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_NULL_TYPE (const location_type& l)
+ Dhcp4Parser::make_NULL_TYPE (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_NULL_TYPE, l);
+ return symbol_type (token::TOKEN_NULL_TYPE, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_DHCP4 (const location_type& l)
+ Dhcp4Parser::make_DHCP4 (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_DHCP4, l);
+ return symbol_type (token::TOKEN_DHCP4, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_CONFIG_CONTROL (const location_type& l)
+ Dhcp4Parser::make_CONFIG_CONTROL (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_CONFIG_CONTROL, l);
+ return symbol_type (token::TOKEN_CONFIG_CONTROL, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_CONFIG_DATABASES (const location_type& l)
+ Dhcp4Parser::make_CONFIG_DATABASES (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_CONFIG_DATABASES, l);
+ return symbol_type (token::TOKEN_CONFIG_DATABASES, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_INTERFACES_CONFIG (const location_type& l)
+ Dhcp4Parser::make_INTERFACES_CONFIG (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_INTERFACES_CONFIG, l);
+ return symbol_type (token::TOKEN_INTERFACES_CONFIG, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_INTERFACES (const location_type& l)
+ Dhcp4Parser::make_INTERFACES (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_INTERFACES, l);
+ return symbol_type (token::TOKEN_INTERFACES, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_DHCP_SOCKET_TYPE (const location_type& l)
+ Dhcp4Parser::make_DHCP_SOCKET_TYPE (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_DHCP_SOCKET_TYPE, l);
+ return symbol_type (token::TOKEN_DHCP_SOCKET_TYPE, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_RAW (const location_type& l)
+ Dhcp4Parser::make_RAW (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_RAW, l);
+ return symbol_type (token::TOKEN_RAW, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_UDP (const location_type& l)
+ Dhcp4Parser::make_UDP (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_UDP, l);
+ return symbol_type (token::TOKEN_UDP, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_OUTBOUND_INTERFACE (const location_type& l)
+ Dhcp4Parser::make_OUTBOUND_INTERFACE (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_OUTBOUND_INTERFACE, l);
+ return symbol_type (token::TOKEN_OUTBOUND_INTERFACE, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_SAME_AS_INBOUND (const location_type& l)
+ Dhcp4Parser::make_SAME_AS_INBOUND (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_SAME_AS_INBOUND, l);
+ return symbol_type (token::TOKEN_SAME_AS_INBOUND, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_USE_ROUTING (const location_type& l)
+ Dhcp4Parser::make_USE_ROUTING (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_USE_ROUTING, l);
+ return symbol_type (token::TOKEN_USE_ROUTING, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_RE_DETECT (const location_type& l)
+ Dhcp4Parser::make_RE_DETECT (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_RE_DETECT, l);
+ return symbol_type (token::TOKEN_RE_DETECT, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_SANITY_CHECKS (const location_type& l)
+ Dhcp4Parser::make_SANITY_CHECKS (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_SANITY_CHECKS, l);
+ return symbol_type (token::TOKEN_SANITY_CHECKS, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_LEASE_CHECKS (const location_type& l)
+ Dhcp4Parser::make_LEASE_CHECKS (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_LEASE_CHECKS, l);
+ return symbol_type (token::TOKEN_LEASE_CHECKS, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_ECHO_CLIENT_ID (const location_type& l)
+ Dhcp4Parser::make_ECHO_CLIENT_ID (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_ECHO_CLIENT_ID, l);
+ return symbol_type (token::TOKEN_ECHO_CLIENT_ID, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_MATCH_CLIENT_ID (const location_type& l)
+ Dhcp4Parser::make_MATCH_CLIENT_ID (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_MATCH_CLIENT_ID, l);
+ return symbol_type (token::TOKEN_MATCH_CLIENT_ID, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_AUTHORITATIVE (const location_type& l)
+ Dhcp4Parser::make_AUTHORITATIVE (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_AUTHORITATIVE, l);
+ return symbol_type (token::TOKEN_AUTHORITATIVE, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_NEXT_SERVER (const location_type& l)
+ Dhcp4Parser::make_NEXT_SERVER (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_NEXT_SERVER, l);
+ return symbol_type (token::TOKEN_NEXT_SERVER, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_SERVER_HOSTNAME (const location_type& l)
+ Dhcp4Parser::make_SERVER_HOSTNAME (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_SERVER_HOSTNAME, l);
+ return symbol_type (token::TOKEN_SERVER_HOSTNAME, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_BOOT_FILE_NAME (const location_type& l)
+ Dhcp4Parser::make_BOOT_FILE_NAME (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_BOOT_FILE_NAME, l);
+ return symbol_type (token::TOKEN_BOOT_FILE_NAME, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_LEASE_DATABASE (const location_type& l)
+ Dhcp4Parser::make_LEASE_DATABASE (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_LEASE_DATABASE, l);
+ return symbol_type (token::TOKEN_LEASE_DATABASE, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_HOSTS_DATABASE (const location_type& l)
+ Dhcp4Parser::make_HOSTS_DATABASE (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_HOSTS_DATABASE, l);
+ return symbol_type (token::TOKEN_HOSTS_DATABASE, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_HOSTS_DATABASES (const location_type& l)
+ Dhcp4Parser::make_HOSTS_DATABASES (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_HOSTS_DATABASES, l);
+ return symbol_type (token::TOKEN_HOSTS_DATABASES, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_TYPE (const location_type& l)
+ Dhcp4Parser::make_TYPE (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_TYPE, l);
+ return symbol_type (token::TOKEN_TYPE, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_MEMFILE (const location_type& l)
+ Dhcp4Parser::make_MEMFILE (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_MEMFILE, l);
+ return symbol_type (token::TOKEN_MEMFILE, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_MYSQL (const location_type& l)
+ Dhcp4Parser::make_MYSQL (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_MYSQL, l);
+ return symbol_type (token::TOKEN_MYSQL, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_POSTGRESQL (const location_type& l)
+ Dhcp4Parser::make_POSTGRESQL (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_POSTGRESQL, l);
+ return symbol_type (token::TOKEN_POSTGRESQL, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_CQL (const location_type& l)
+ Dhcp4Parser::make_CQL (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_CQL, l);
+ return symbol_type (token::TOKEN_CQL, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_USER (const location_type& l)
+ Dhcp4Parser::make_USER (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_USER, l);
+ return symbol_type (token::TOKEN_USER, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_PASSWORD (const location_type& l)
+ Dhcp4Parser::make_PASSWORD (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_PASSWORD, l);
+ return symbol_type (token::TOKEN_PASSWORD, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_HOST (const location_type& l)
+ Dhcp4Parser::make_HOST (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_HOST, l);
+ return symbol_type (token::TOKEN_HOST, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_PORT (const location_type& l)
+ Dhcp4Parser::make_PORT (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_PORT, l);
+ return symbol_type (token::TOKEN_PORT, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_PERSIST (const location_type& l)
+ Dhcp4Parser::make_PERSIST (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_PERSIST, l);
+ return symbol_type (token::TOKEN_PERSIST, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_LFC_INTERVAL (const location_type& l)
+ Dhcp4Parser::make_LFC_INTERVAL (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_LFC_INTERVAL, l);
+ return symbol_type (token::TOKEN_LFC_INTERVAL, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_READONLY (const location_type& l)
+ Dhcp4Parser::make_READONLY (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_READONLY, l);
+ return symbol_type (token::TOKEN_READONLY, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_CONNECT_TIMEOUT (const location_type& l)
+ Dhcp4Parser::make_CONNECT_TIMEOUT (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_CONNECT_TIMEOUT, l);
+ return symbol_type (token::TOKEN_CONNECT_TIMEOUT, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_CONTACT_POINTS (const location_type& l)
+ Dhcp4Parser::make_CONTACT_POINTS (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_CONTACT_POINTS, l);
+ return symbol_type (token::TOKEN_CONTACT_POINTS, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_KEYSPACE (const location_type& l)
+ Dhcp4Parser::make_KEYSPACE (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_KEYSPACE, l);
+ return symbol_type (token::TOKEN_KEYSPACE, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_MAX_RECONNECT_TRIES (const location_type& l)
+ Dhcp4Parser::make_MAX_RECONNECT_TRIES (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_MAX_RECONNECT_TRIES, l);
+ return symbol_type (token::TOKEN_MAX_RECONNECT_TRIES, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_RECONNECT_WAIT_TIME (const location_type& l)
+ Dhcp4Parser::make_RECONNECT_WAIT_TIME (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_RECONNECT_WAIT_TIME, l);
+ return symbol_type (token::TOKEN_RECONNECT_WAIT_TIME, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_REQUEST_TIMEOUT (const location_type& l)
+ Dhcp4Parser::make_REQUEST_TIMEOUT (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_REQUEST_TIMEOUT, l);
+ return symbol_type (token::TOKEN_REQUEST_TIMEOUT, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_TCP_KEEPALIVE (const location_type& l)
+ Dhcp4Parser::make_TCP_KEEPALIVE (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_TCP_KEEPALIVE, l);
+ return symbol_type (token::TOKEN_TCP_KEEPALIVE, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_TCP_NODELAY (const location_type& l)
+ Dhcp4Parser::make_TCP_NODELAY (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_TCP_NODELAY, l);
+ return symbol_type (token::TOKEN_TCP_NODELAY, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_VALID_LIFETIME (const location_type& l)
+ Dhcp4Parser::make_VALID_LIFETIME (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_VALID_LIFETIME, l);
+ return symbol_type (token::TOKEN_VALID_LIFETIME, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_RENEW_TIMER (const location_type& l)
+ Dhcp4Parser::make_RENEW_TIMER (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_RENEW_TIMER, l);
+ return symbol_type (token::TOKEN_RENEW_TIMER, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_REBIND_TIMER (const location_type& l)
+ Dhcp4Parser::make_REBIND_TIMER (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_REBIND_TIMER, l);
+ return symbol_type (token::TOKEN_REBIND_TIMER, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_DECLINE_PROBATION_PERIOD (const location_type& l)
+ Dhcp4Parser::make_DECLINE_PROBATION_PERIOD (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_DECLINE_PROBATION_PERIOD, l);
+ return symbol_type (token::TOKEN_DECLINE_PROBATION_PERIOD, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_SERVER_TAG (const location_type& l)
+ Dhcp4Parser::make_SERVER_TAG (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_SERVER_TAG, l);
+ return symbol_type (token::TOKEN_SERVER_TAG, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_SUBNET4 (const location_type& l)
+ Dhcp4Parser::make_SUBNET4 (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_SUBNET4, l);
+ return symbol_type (token::TOKEN_SUBNET4, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_SUBNET_4O6_INTERFACE (const location_type& l)
+ Dhcp4Parser::make_SUBNET_4O6_INTERFACE (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_SUBNET_4O6_INTERFACE, l);
+ return symbol_type (token::TOKEN_SUBNET_4O6_INTERFACE, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_SUBNET_4O6_INTERFACE_ID (const location_type& l)
+ Dhcp4Parser::make_SUBNET_4O6_INTERFACE_ID (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_SUBNET_4O6_INTERFACE_ID, l);
+ return symbol_type (token::TOKEN_SUBNET_4O6_INTERFACE_ID, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_SUBNET_4O6_SUBNET (const location_type& l)
+ Dhcp4Parser::make_SUBNET_4O6_SUBNET (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_SUBNET_4O6_SUBNET, l);
+ return symbol_type (token::TOKEN_SUBNET_4O6_SUBNET, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_OPTION_DEF (const location_type& l)
+ Dhcp4Parser::make_OPTION_DEF (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_OPTION_DEF, l);
+ return symbol_type (token::TOKEN_OPTION_DEF, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_OPTION_DATA (const location_type& l)
+ Dhcp4Parser::make_OPTION_DATA (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_OPTION_DATA, l);
+ return symbol_type (token::TOKEN_OPTION_DATA, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_NAME (const location_type& l)
+ Dhcp4Parser::make_NAME (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_NAME, l);
+ return symbol_type (token::TOKEN_NAME, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_DATA (const location_type& l)
+ Dhcp4Parser::make_DATA (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_DATA, l);
+ return symbol_type (token::TOKEN_DATA, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_CODE (const location_type& l)
+ Dhcp4Parser::make_CODE (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_CODE, l);
+ return symbol_type (token::TOKEN_CODE, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_SPACE (const location_type& l)
+ Dhcp4Parser::make_SPACE (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_SPACE, l);
+ return symbol_type (token::TOKEN_SPACE, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_CSV_FORMAT (const location_type& l)
+ Dhcp4Parser::make_CSV_FORMAT (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_CSV_FORMAT, l);
+ return symbol_type (token::TOKEN_CSV_FORMAT, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_ALWAYS_SEND (const location_type& l)
+ Dhcp4Parser::make_ALWAYS_SEND (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_ALWAYS_SEND, l);
+ return symbol_type (token::TOKEN_ALWAYS_SEND, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_RECORD_TYPES (const location_type& l)
+ Dhcp4Parser::make_RECORD_TYPES (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_RECORD_TYPES, l);
+ return symbol_type (token::TOKEN_RECORD_TYPES, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_ENCAPSULATE (const location_type& l)
+ Dhcp4Parser::make_ENCAPSULATE (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_ENCAPSULATE, l);
+ return symbol_type (token::TOKEN_ENCAPSULATE, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_ARRAY (const location_type& l)
+ Dhcp4Parser::make_ARRAY (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_ARRAY, l);
+ return symbol_type (token::TOKEN_ARRAY, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_SHARED_NETWORKS (const location_type& l)
+ Dhcp4Parser::make_SHARED_NETWORKS (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_SHARED_NETWORKS, l);
+ return symbol_type (token::TOKEN_SHARED_NETWORKS, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_POOLS (const location_type& l)
+ Dhcp4Parser::make_POOLS (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_POOLS, l);
+ return symbol_type (token::TOKEN_POOLS, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_POOL (const location_type& l)
+ Dhcp4Parser::make_POOL (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_POOL, l);
+ return symbol_type (token::TOKEN_POOL, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_USER_CONTEXT (const location_type& l)
+ Dhcp4Parser::make_USER_CONTEXT (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_USER_CONTEXT, l);
+ return symbol_type (token::TOKEN_USER_CONTEXT, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_COMMENT (const location_type& l)
+ Dhcp4Parser::make_COMMENT (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_COMMENT, l);
+ return symbol_type (token::TOKEN_COMMENT, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_SUBNET (const location_type& l)
+ Dhcp4Parser::make_SUBNET (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_SUBNET, l);
+ return symbol_type (token::TOKEN_SUBNET, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_INTERFACE (const location_type& l)
+ Dhcp4Parser::make_INTERFACE (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_INTERFACE, l);
+ return symbol_type (token::TOKEN_INTERFACE, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_ID (const location_type& l)
+ Dhcp4Parser::make_ID (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_ID, l);
+ return symbol_type (token::TOKEN_ID, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_RESERVATION_MODE (const location_type& l)
+ Dhcp4Parser::make_RESERVATION_MODE (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_RESERVATION_MODE, l);
+ return symbol_type (token::TOKEN_RESERVATION_MODE, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_DISABLED (const location_type& l)
+ Dhcp4Parser::make_DISABLED (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_DISABLED, l);
+ return symbol_type (token::TOKEN_DISABLED, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_OUT_OF_POOL (const location_type& l)
+ Dhcp4Parser::make_OUT_OF_POOL (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_OUT_OF_POOL, l);
+ return symbol_type (token::TOKEN_OUT_OF_POOL, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_GLOBAL (const location_type& l)
+ Dhcp4Parser::make_GLOBAL (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_GLOBAL, l);
+ return symbol_type (token::TOKEN_GLOBAL, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_ALL (const location_type& l)
+ Dhcp4Parser::make_ALL (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_ALL, l);
+ return symbol_type (token::TOKEN_ALL, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_HOST_RESERVATION_IDENTIFIERS (const location_type& l)
+ Dhcp4Parser::make_HOST_RESERVATION_IDENTIFIERS (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_HOST_RESERVATION_IDENTIFIERS, l);
+ return symbol_type (token::TOKEN_HOST_RESERVATION_IDENTIFIERS, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_CLIENT_CLASSES (const location_type& l)
+ Dhcp4Parser::make_CLIENT_CLASSES (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_CLIENT_CLASSES, l);
+ return symbol_type (token::TOKEN_CLIENT_CLASSES, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_REQUIRE_CLIENT_CLASSES (const location_type& l)
+ Dhcp4Parser::make_REQUIRE_CLIENT_CLASSES (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_REQUIRE_CLIENT_CLASSES, l);
+ return symbol_type (token::TOKEN_REQUIRE_CLIENT_CLASSES, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_TEST (const location_type& l)
+ Dhcp4Parser::make_TEST (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_TEST, l);
+ return symbol_type (token::TOKEN_TEST, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_ONLY_IF_REQUIRED (const location_type& l)
+ Dhcp4Parser::make_ONLY_IF_REQUIRED (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_ONLY_IF_REQUIRED, l);
+ return symbol_type (token::TOKEN_ONLY_IF_REQUIRED, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_CLIENT_CLASS (const location_type& l)
+ Dhcp4Parser::make_CLIENT_CLASS (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_CLIENT_CLASS, l);
+ return symbol_type (token::TOKEN_CLIENT_CLASS, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_RESERVATIONS (const location_type& l)
+ Dhcp4Parser::make_RESERVATIONS (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_RESERVATIONS, l);
+ return symbol_type (token::TOKEN_RESERVATIONS, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_DUID (const location_type& l)
+ Dhcp4Parser::make_DUID (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_DUID, l);
+ return symbol_type (token::TOKEN_DUID, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_HW_ADDRESS (const location_type& l)
+ Dhcp4Parser::make_HW_ADDRESS (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_HW_ADDRESS, l);
+ return symbol_type (token::TOKEN_HW_ADDRESS, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_CIRCUIT_ID (const location_type& l)
+ Dhcp4Parser::make_CIRCUIT_ID (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_CIRCUIT_ID, l);
+ return symbol_type (token::TOKEN_CIRCUIT_ID, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_CLIENT_ID (const location_type& l)
+ Dhcp4Parser::make_CLIENT_ID (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_CLIENT_ID, l);
+ return symbol_type (token::TOKEN_CLIENT_ID, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_HOSTNAME (const location_type& l)
+ Dhcp4Parser::make_HOSTNAME (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_HOSTNAME, l);
+ return symbol_type (token::TOKEN_HOSTNAME, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_FLEX_ID (const location_type& l)
+ Dhcp4Parser::make_FLEX_ID (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_FLEX_ID, l);
+ return symbol_type (token::TOKEN_FLEX_ID, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_RELAY (const location_type& l)
+ Dhcp4Parser::make_RELAY (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_RELAY, l);
+ return symbol_type (token::TOKEN_RELAY, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_IP_ADDRESS (const location_type& l)
+ Dhcp4Parser::make_IP_ADDRESS (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_IP_ADDRESS, l);
+ return symbol_type (token::TOKEN_IP_ADDRESS, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_IP_ADDRESSES (const location_type& l)
+ Dhcp4Parser::make_IP_ADDRESSES (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_IP_ADDRESSES, l);
+ return symbol_type (token::TOKEN_IP_ADDRESSES, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_HOOKS_LIBRARIES (const location_type& l)
+ Dhcp4Parser::make_HOOKS_LIBRARIES (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_HOOKS_LIBRARIES, l);
+ return symbol_type (token::TOKEN_HOOKS_LIBRARIES, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_LIBRARY (const location_type& l)
+ Dhcp4Parser::make_LIBRARY (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_LIBRARY, l);
+ return symbol_type (token::TOKEN_LIBRARY, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_PARAMETERS (const location_type& l)
+ Dhcp4Parser::make_PARAMETERS (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_PARAMETERS, l);
+ return symbol_type (token::TOKEN_PARAMETERS, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_EXPIRED_LEASES_PROCESSING (const location_type& l)
+ Dhcp4Parser::make_EXPIRED_LEASES_PROCESSING (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_EXPIRED_LEASES_PROCESSING, l);
+ return symbol_type (token::TOKEN_EXPIRED_LEASES_PROCESSING, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_RECLAIM_TIMER_WAIT_TIME (const location_type& l)
+ Dhcp4Parser::make_RECLAIM_TIMER_WAIT_TIME (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_RECLAIM_TIMER_WAIT_TIME, l);
+ return symbol_type (token::TOKEN_RECLAIM_TIMER_WAIT_TIME, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_FLUSH_RECLAIMED_TIMER_WAIT_TIME (const location_type& l)
+ Dhcp4Parser::make_FLUSH_RECLAIMED_TIMER_WAIT_TIME (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_FLUSH_RECLAIMED_TIMER_WAIT_TIME, l);
+ return symbol_type (token::TOKEN_FLUSH_RECLAIMED_TIMER_WAIT_TIME, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_HOLD_RECLAIMED_TIME (const location_type& l)
+ Dhcp4Parser::make_HOLD_RECLAIMED_TIME (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_HOLD_RECLAIMED_TIME, l);
+ return symbol_type (token::TOKEN_HOLD_RECLAIMED_TIME, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_MAX_RECLAIM_LEASES (const location_type& l)
+ Dhcp4Parser::make_MAX_RECLAIM_LEASES (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_MAX_RECLAIM_LEASES, l);
+ return symbol_type (token::TOKEN_MAX_RECLAIM_LEASES, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_MAX_RECLAIM_TIME (const location_type& l)
+ Dhcp4Parser::make_MAX_RECLAIM_TIME (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_MAX_RECLAIM_TIME, l);
+ return symbol_type (token::TOKEN_MAX_RECLAIM_TIME, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_UNWARNED_RECLAIM_CYCLES (const location_type& l)
+ Dhcp4Parser::make_UNWARNED_RECLAIM_CYCLES (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_UNWARNED_RECLAIM_CYCLES, l);
+ return symbol_type (token::TOKEN_UNWARNED_RECLAIM_CYCLES, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_DHCP4O6_PORT (const location_type& l)
+ Dhcp4Parser::make_DHCP4O6_PORT (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_DHCP4O6_PORT, l);
+ return symbol_type (token::TOKEN_DHCP4O6_PORT, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_CONTROL_SOCKET (const location_type& l)
+ Dhcp4Parser::make_CONTROL_SOCKET (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_CONTROL_SOCKET, l);
+ return symbol_type (token::TOKEN_CONTROL_SOCKET, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_SOCKET_TYPE (const location_type& l)
+ Dhcp4Parser::make_SOCKET_TYPE (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_SOCKET_TYPE, l);
+ return symbol_type (token::TOKEN_SOCKET_TYPE, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_SOCKET_NAME (const location_type& l)
+ Dhcp4Parser::make_SOCKET_NAME (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_SOCKET_NAME, l);
+ return symbol_type (token::TOKEN_SOCKET_NAME, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_DHCP_QUEUE_CONTROL (const location_type& l)
+ Dhcp4Parser::make_DHCP_QUEUE_CONTROL (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_DHCP_QUEUE_CONTROL, l);
+ return symbol_type (token::TOKEN_DHCP_QUEUE_CONTROL, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_DHCP_DDNS (const location_type& l)
+ Dhcp4Parser::make_DHCP_DDNS (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_DHCP_DDNS, l);
+ return symbol_type (token::TOKEN_DHCP_DDNS, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_ENABLE_UPDATES (const location_type& l)
+ Dhcp4Parser::make_ENABLE_UPDATES (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_ENABLE_UPDATES, l);
+ return symbol_type (token::TOKEN_ENABLE_UPDATES, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_QUALIFYING_SUFFIX (const location_type& l)
+ Dhcp4Parser::make_QUALIFYING_SUFFIX (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_QUALIFYING_SUFFIX, l);
+ return symbol_type (token::TOKEN_QUALIFYING_SUFFIX, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_SERVER_IP (const location_type& l)
+ Dhcp4Parser::make_SERVER_IP (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_SERVER_IP, l);
+ return symbol_type (token::TOKEN_SERVER_IP, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_SERVER_PORT (const location_type& l)
+ Dhcp4Parser::make_SERVER_PORT (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_SERVER_PORT, l);
+ return symbol_type (token::TOKEN_SERVER_PORT, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_SENDER_IP (const location_type& l)
+ Dhcp4Parser::make_SENDER_IP (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_SENDER_IP, l);
+ return symbol_type (token::TOKEN_SENDER_IP, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_SENDER_PORT (const location_type& l)
+ Dhcp4Parser::make_SENDER_PORT (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_SENDER_PORT, l);
+ return symbol_type (token::TOKEN_SENDER_PORT, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_MAX_QUEUE_SIZE (const location_type& l)
+ Dhcp4Parser::make_MAX_QUEUE_SIZE (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_MAX_QUEUE_SIZE, l);
+ return symbol_type (token::TOKEN_MAX_QUEUE_SIZE, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_NCR_PROTOCOL (const location_type& l)
+ Dhcp4Parser::make_NCR_PROTOCOL (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_NCR_PROTOCOL, l);
+ return symbol_type (token::TOKEN_NCR_PROTOCOL, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_NCR_FORMAT (const location_type& l)
+ Dhcp4Parser::make_NCR_FORMAT (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_NCR_FORMAT, l);
+ return symbol_type (token::TOKEN_NCR_FORMAT, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_ALWAYS_INCLUDE_FQDN (const location_type& l)
+ Dhcp4Parser::make_ALWAYS_INCLUDE_FQDN (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_ALWAYS_INCLUDE_FQDN, l);
+ return symbol_type (token::TOKEN_ALWAYS_INCLUDE_FQDN, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_OVERRIDE_NO_UPDATE (const location_type& l)
+ Dhcp4Parser::make_OVERRIDE_NO_UPDATE (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_OVERRIDE_NO_UPDATE, l);
+ return symbol_type (token::TOKEN_OVERRIDE_NO_UPDATE, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_OVERRIDE_CLIENT_UPDATE (const location_type& l)
+ Dhcp4Parser::make_OVERRIDE_CLIENT_UPDATE (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_OVERRIDE_CLIENT_UPDATE, l);
+ return symbol_type (token::TOKEN_OVERRIDE_CLIENT_UPDATE, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_REPLACE_CLIENT_NAME (const location_type& l)
+ Dhcp4Parser::make_REPLACE_CLIENT_NAME (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_REPLACE_CLIENT_NAME, l);
+ return symbol_type (token::TOKEN_REPLACE_CLIENT_NAME, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_GENERATED_PREFIX (const location_type& l)
+ Dhcp4Parser::make_GENERATED_PREFIX (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_GENERATED_PREFIX, l);
+ return symbol_type (token::TOKEN_GENERATED_PREFIX, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_TCP (const location_type& l)
+ Dhcp4Parser::make_TCP (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_TCP, l);
+ return symbol_type (token::TOKEN_TCP, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_JSON (const location_type& l)
+ Dhcp4Parser::make_JSON (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_JSON, l);
+ return symbol_type (token::TOKEN_JSON, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_WHEN_PRESENT (const location_type& l)
+ Dhcp4Parser::make_WHEN_PRESENT (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_WHEN_PRESENT, l);
+ return symbol_type (token::TOKEN_WHEN_PRESENT, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_NEVER (const location_type& l)
+ Dhcp4Parser::make_NEVER (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_NEVER, l);
+ return symbol_type (token::TOKEN_NEVER, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_ALWAYS (const location_type& l)
+ Dhcp4Parser::make_ALWAYS (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_ALWAYS, l);
+ return symbol_type (token::TOKEN_ALWAYS, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_WHEN_NOT_PRESENT (const location_type& l)
+ Dhcp4Parser::make_WHEN_NOT_PRESENT (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_WHEN_NOT_PRESENT, l);
+ return symbol_type (token::TOKEN_WHEN_NOT_PRESENT, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_HOSTNAME_CHAR_SET (const location_type& l)
+ Dhcp4Parser::make_HOSTNAME_CHAR_SET (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_HOSTNAME_CHAR_SET, l);
+ return symbol_type (token::TOKEN_HOSTNAME_CHAR_SET, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_HOSTNAME_CHAR_REPLACEMENT (const location_type& l)
+ Dhcp4Parser::make_HOSTNAME_CHAR_REPLACEMENT (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_HOSTNAME_CHAR_REPLACEMENT, l);
+ return symbol_type (token::TOKEN_HOSTNAME_CHAR_REPLACEMENT, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_LOGGING (const location_type& l)
+ Dhcp4Parser::make_LOGGING (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_LOGGING, l);
+ return symbol_type (token::TOKEN_LOGGING, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_LOGGERS (const location_type& l)
+ Dhcp4Parser::make_LOGGERS (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_LOGGERS, l);
+ return symbol_type (token::TOKEN_LOGGERS, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_OUTPUT_OPTIONS (const location_type& l)
+ Dhcp4Parser::make_OUTPUT_OPTIONS (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_OUTPUT_OPTIONS, l);
+ return symbol_type (token::TOKEN_OUTPUT_OPTIONS, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_OUTPUT (const location_type& l)
+ Dhcp4Parser::make_OUTPUT (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_OUTPUT, l);
+ return symbol_type (token::TOKEN_OUTPUT, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_DEBUGLEVEL (const location_type& l)
+ Dhcp4Parser::make_DEBUGLEVEL (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_DEBUGLEVEL, l);
+ return symbol_type (token::TOKEN_DEBUGLEVEL, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_SEVERITY (const location_type& l)
+ Dhcp4Parser::make_SEVERITY (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_SEVERITY, l);
+ return symbol_type (token::TOKEN_SEVERITY, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_FLUSH (const location_type& l)
+ Dhcp4Parser::make_FLUSH (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_FLUSH, l);
+ return symbol_type (token::TOKEN_FLUSH, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_MAXSIZE (const location_type& l)
+ Dhcp4Parser::make_MAXSIZE (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_MAXSIZE, l);
+ return symbol_type (token::TOKEN_MAXSIZE, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_MAXVER (const location_type& l)
+ Dhcp4Parser::make_MAXVER (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_MAXVER, l);
+ return symbol_type (token::TOKEN_MAXVER, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_DHCP6 (const location_type& l)
+ Dhcp4Parser::make_DHCP6 (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_DHCP6, l);
+ return symbol_type (token::TOKEN_DHCP6, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_DHCPDDNS (const location_type& l)
+ Dhcp4Parser::make_DHCPDDNS (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_DHCPDDNS, l);
+ return symbol_type (token::TOKEN_DHCPDDNS, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_CONTROL_AGENT (const location_type& l)
+ Dhcp4Parser::make_CONTROL_AGENT (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_CONTROL_AGENT, l);
+ return symbol_type (token::TOKEN_CONTROL_AGENT, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_TOPLEVEL_JSON (const location_type& l)
+ Dhcp4Parser::make_TOPLEVEL_JSON (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_TOPLEVEL_JSON, l);
+ return symbol_type (token::TOKEN_TOPLEVEL_JSON, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_TOPLEVEL_DHCP4 (const location_type& l)
+ Dhcp4Parser::make_TOPLEVEL_DHCP4 (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_TOPLEVEL_DHCP4, l);
+ return symbol_type (token::TOKEN_TOPLEVEL_DHCP4, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_SUB_DHCP4 (const location_type& l)
+ Dhcp4Parser::make_SUB_DHCP4 (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_SUB_DHCP4, l);
+ return symbol_type (token::TOKEN_SUB_DHCP4, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_SUB_INTERFACES4 (const location_type& l)
+ Dhcp4Parser::make_SUB_INTERFACES4 (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_SUB_INTERFACES4, l);
+ return symbol_type (token::TOKEN_SUB_INTERFACES4, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_SUB_SUBNET4 (const location_type& l)
+ Dhcp4Parser::make_SUB_SUBNET4 (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_SUB_SUBNET4, l);
+ return symbol_type (token::TOKEN_SUB_SUBNET4, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_SUB_POOL4 (const location_type& l)
+ Dhcp4Parser::make_SUB_POOL4 (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_SUB_POOL4, l);
+ return symbol_type (token::TOKEN_SUB_POOL4, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_SUB_RESERVATION (const location_type& l)
+ Dhcp4Parser::make_SUB_RESERVATION (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_SUB_RESERVATION, l);
+ return symbol_type (token::TOKEN_SUB_RESERVATION, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_SUB_OPTION_DEFS (const location_type& l)
+ Dhcp4Parser::make_SUB_OPTION_DEFS (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_SUB_OPTION_DEFS, l);
+ return symbol_type (token::TOKEN_SUB_OPTION_DEFS, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_SUB_OPTION_DEF (const location_type& l)
+ Dhcp4Parser::make_SUB_OPTION_DEF (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_SUB_OPTION_DEF, l);
+ return symbol_type (token::TOKEN_SUB_OPTION_DEF, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_SUB_OPTION_DATA (const location_type& l)
+ Dhcp4Parser::make_SUB_OPTION_DATA (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_SUB_OPTION_DATA, l);
+ return symbol_type (token::TOKEN_SUB_OPTION_DATA, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_SUB_HOOKS_LIBRARY (const location_type& l)
+ Dhcp4Parser::make_SUB_HOOKS_LIBRARY (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_SUB_HOOKS_LIBRARY, l);
+ return symbol_type (token::TOKEN_SUB_HOOKS_LIBRARY, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_SUB_DHCP_DDNS (const location_type& l)
+ Dhcp4Parser::make_SUB_DHCP_DDNS (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_SUB_DHCP_DDNS, l);
+ return symbol_type (token::TOKEN_SUB_DHCP_DDNS, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_SUB_LOGGING (const location_type& l)
+ Dhcp4Parser::make_SUB_LOGGING (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_SUB_LOGGING, l);
+ return symbol_type (token::TOKEN_SUB_LOGGING, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_SUB_CONFIG_CONTROL (const location_type& l)
+ Dhcp4Parser::make_SUB_CONFIG_CONTROL (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_SUB_CONFIG_CONTROL, l);
+ return symbol_type (token::TOKEN_SUB_CONFIG_CONTROL, YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_STRING (const std::string& v, const location_type& l)
+ Dhcp4Parser::make_STRING (YY_COPY (std::string) v, YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_STRING, v, l);
+ return symbol_type (token::TOKEN_STRING, YY_MOVE (v), YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_INTEGER (const int64_t& v, const location_type& l)
+ Dhcp4Parser::make_INTEGER (YY_COPY (int64_t) v, YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_INTEGER, v, l);
+ return symbol_type (token::TOKEN_INTEGER, YY_MOVE (v), YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_FLOAT (const double& v, const location_type& l)
+ Dhcp4Parser::make_FLOAT (YY_COPY (double) v, YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_FLOAT, v, l);
+ return symbol_type (token::TOKEN_FLOAT, YY_MOVE (v), YY_MOVE (l));
}
+ inline
Dhcp4Parser::symbol_type
- Dhcp4Parser::make_BOOLEAN (const bool& v, const location_type& l)
+ Dhcp4Parser::make_BOOLEAN (YY_COPY (bool) v, YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_BOOLEAN, v, l);
+ return symbol_type (token::TOKEN_BOOLEAN, YY_MOVE (v), YY_MOVE (l));
}
-#line 14 "dhcp4_parser.yy" // lalr1.cc:379
+#line 14 "dhcp4_parser.yy" // lalr1.cc:404
} } // isc::dhcp
-#line 2914 "dhcp4_parser.h" // lalr1.cc:379
+#line 3232 "dhcp4_parser.h" // lalr1.cc:404
-// Generated 201811151407
-// A Bison parser, made by GNU Bison 3.0.5.
+// Generated 201811172153
+// A Bison parser, made by GNU Bison 3.2.1.
// Locations for Bison parsers in C++
#ifndef YY_PARSER4_LOCATION_HH_INCLUDED
# define YY_PARSER4_LOCATION_HH_INCLUDED
-# include "position.hh"
+# include <algorithm> // std::max
+# include <iostream>
+# include <string>
-#line 14 "dhcp4_parser.yy" // location.cc:292
+# ifndef YY_NULLPTR
+# if defined __cplusplus
+# if 201103L <= __cplusplus
+# define YY_NULLPTR nullptr
+# else
+# define YY_NULLPTR 0
+# endif
+# else
+# define YY_NULLPTR ((void*)0)
+# endif
+# endif
+
+#line 14 "dhcp4_parser.yy" // location.cc:339
namespace isc { namespace dhcp {
-#line 46 "location.hh" // location.cc:292
- /// Abstract a location.
+#line 60 "location.hh" // location.cc:339
+ /// A point in a source file.
+ class position
+ {
+ public:
+ /// Construct a position.
+ explicit position (std::string* f = YY_NULLPTR,
+ unsigned l = 1u,
+ unsigned c = 1u)
+ : filename (f)
+ , line (l)
+ , column (c)
+ {}
+
+
+ /// Initialization.
+ void initialize (std::string* fn = YY_NULLPTR,
+ unsigned l = 1u,
+ unsigned c = 1u)
+ {
+ filename = fn;
+ line = l;
+ column = c;
+ }
+
+ /** \name Line and Column related manipulators
+ ** \{ */
+ /// (line related) Advance to the COUNT next lines.
+ void lines (int count = 1)
+ {
+ if (count)
+ {
+ column = 1u;
+ line = add_ (line, count, 1);
+ }
+ }
+
+ /// (column related) Advance to the COUNT next columns.
+ void columns (int count = 1)
+ {
+ column = add_ (column, count, 1);
+ }
+ /** \} */
+
+ /// File name to which this position refers.
+ std::string* filename;
+ /// Current line number.
+ unsigned line;
+ /// Current column number.
+ unsigned column;
+
+ private:
+ /// Compute max (min, lhs+rhs).
+ static unsigned add_ (unsigned lhs, int rhs, int min)
+ {
+ return static_cast<unsigned> (std::max (min,
+ static_cast<int> (lhs) + rhs));
+ }
+ };
+
+ /// Add \a width columns, in place.
+ inline position&
+ operator+= (position& res, int width)
+ {
+ res.columns (width);
+ return res;
+ }
+
+ /// Add \a width columns.
+ inline position
+ operator+ (position res, int width)
+ {
+ return res += width;
+ }
+
+ /// Subtract \a width columns, in place.
+ inline position&
+ operator-= (position& res, int width)
+ {
+ return res += -width;
+ }
+
+ /// Subtract \a width columns.
+ inline position
+ operator- (position res, int width)
+ {
+ return res -= width;
+ }
+
+ /// Compare two position objects.
+ inline bool
+ operator== (const position& pos1, const position& pos2)
+ {
+ return (pos1.line == pos2.line
+ && pos1.column == pos2.column
+ && (pos1.filename == pos2.filename
+ || (pos1.filename && pos2.filename
+ && *pos1.filename == *pos2.filename)));
+ }
+
+ /// Compare two position objects.
+ inline bool
+ operator!= (const position& pos1, const position& pos2)
+ {
+ return !(pos1 == pos2);
+ }
+
+ /** \brief Intercept output stream redirection.
+ ** \param ostr the destination output stream
+ ** \param pos a reference to the position to redirect
+ */
+ template <typename YYChar>
+ std::basic_ostream<YYChar>&
+ operator<< (std::basic_ostream<YYChar>& ostr, const position& pos)
+ {
+ if (pos.filename)
+ ostr << *pos.filename << ':';
+ return ostr << pos.line << '.' << pos.column;
+ }
+
+ /// Two points in a source file.
class location
{
public:
** Avoid duplicate information.
*/
template <typename YYChar>
- inline std::basic_ostream<YYChar>&
+ std::basic_ostream<YYChar>&
operator<< (std::basic_ostream<YYChar>& ostr, const location& loc)
{
unsigned end_col = 0 < loc.end.column ? loc.end.column - 1 : 0;
return ostr;
}
-#line 14 "dhcp4_parser.yy" // location.cc:292
+#line 14 "dhcp4_parser.yy" // location.cc:339
} } // isc::dhcp
-#line 189 "location.hh" // location.cc:292
+#line 322 "location.hh" // location.cc:339
#endif // !YY_PARSER4_LOCATION_HH_INCLUDED
-// Generated 201811151407
-// A Bison parser, made by GNU Bison 3.0.5.
-
-// Positions for Bison parsers in C++
-
-// Copyright (C) 2002-2015, 2018 Free Software Foundation, Inc.
-
-// This program is free software: you can redistribute it and/or modify
-// it under the terms of the GNU General Public License as published by
-// the Free Software Foundation, either version 3 of the License, or
-// (at your option) any later version.
-
-// This program is distributed in the hope that it will be useful,
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-// GNU General Public License for more details.
-
-// You should have received a copy of the GNU General Public License
-// along with this program. If not, see <http://www.gnu.org/licenses/>.
-
-// As a special exception, you may create a larger work that contains
-// part or all of the Bison parser skeleton and distribute that work
-// under terms of your choice, so long as that work isn't itself a
-// parser generator using the skeleton or a modified version thereof
-// as a parser skeleton. Alternatively, if you modify or redistribute
-// the parser skeleton itself, you may (at your option) remove this
-// special exception, which will cause the skeleton and the resulting
-// Bison output files to be licensed under the GNU General Public
-// License without this special exception.
-
-// This special exception was added by the Free Software Foundation in
-// version 2.2 of Bison.
-
-/**
- ** \file position.hh
- ** Define the isc::dhcp::position class.
- */
-
-#ifndef YY_PARSER4_POSITION_HH_INCLUDED
-# define YY_PARSER4_POSITION_HH_INCLUDED
-
-# include <algorithm> // std::max
-# include <iostream>
-# include <string>
-
-# ifndef YY_NULLPTR
-# if defined __cplusplus && 201103L <= __cplusplus
-# define YY_NULLPTR nullptr
-# else
-# define YY_NULLPTR 0
-# endif
-# endif
-
-#line 14 "dhcp4_parser.yy" // location.cc:292
-namespace isc { namespace dhcp {
-#line 56 "position.hh" // location.cc:292
- /// Abstract a position.
- class position
- {
- public:
- /// Construct a position.
- explicit position (std::string* f = YY_NULLPTR,
- unsigned l = 1u,
- unsigned c = 1u)
- : filename (f)
- , line (l)
- , column (c)
- {}
-
-
- /// Initialization.
- void initialize (std::string* fn = YY_NULLPTR,
- unsigned l = 1u,
- unsigned c = 1u)
- {
- filename = fn;
- line = l;
- column = c;
- }
-
- /** \name Line and Column related manipulators
- ** \{ */
- /// (line related) Advance to the COUNT next lines.
- void lines (int count = 1)
- {
- if (count)
- {
- column = 1u;
- line = add_ (line, count, 1);
- }
- }
-
- /// (column related) Advance to the COUNT next columns.
- void columns (int count = 1)
- {
- column = add_ (column, count, 1);
- }
- /** \} */
-
- /// File name to which this position refers.
- std::string* filename;
- /// Current line number.
- unsigned line;
- /// Current column number.
- unsigned column;
-
- private:
- /// Compute max(min, lhs+rhs) (provided min <= lhs).
- static unsigned add_ (unsigned lhs, int rhs, unsigned min)
- {
- return (0 < rhs || -static_cast<unsigned>(rhs) < lhs
- ? rhs + lhs
- : min);
- }
- };
-
- /// Add \a width columns, in place.
- inline position&
- operator+= (position& res, int width)
- {
- res.columns (width);
- return res;
- }
-
- /// Add \a width columns.
- inline position
- operator+ (position res, int width)
- {
- return res += width;
- }
-
- /// Subtract \a width columns, in place.
- inline position&
- operator-= (position& res, int width)
- {
- return res += -width;
- }
-
- /// Subtract \a width columns.
- inline position
- operator- (position res, int width)
- {
- return res -= width;
- }
-
- /// Compare two position objects.
- inline bool
- operator== (const position& pos1, const position& pos2)
- {
- return (pos1.line == pos2.line
- && pos1.column == pos2.column
- && (pos1.filename == pos2.filename
- || (pos1.filename && pos2.filename
- && *pos1.filename == *pos2.filename)));
- }
-
- /// Compare two position objects.
- inline bool
- operator!= (const position& pos1, const position& pos2)
- {
- return !(pos1 == pos2);
- }
-
- /** \brief Intercept output stream redirection.
- ** \param ostr the destination output stream
- ** \param pos a reference to the position to redirect
- */
- template <typename YYChar>
- inline std::basic_ostream<YYChar>&
- operator<< (std::basic_ostream<YYChar>& ostr, const position& pos)
- {
- if (pos.filename)
- ostr << *pos.filename << ':';
- return ostr << pos.line << '.' << pos.column;
- }
-
-#line 14 "dhcp4_parser.yy" // location.cc:292
-} } // isc::dhcp
-#line 179 "position.hh" // location.cc:292
-#endif // !YY_PARSER4_POSITION_HH_INCLUDED
+// Generated 201811172153
+// A Bison parser, made by GNU Bison 3.2.1.
+
+// Starting with Bison 3.2, this file is useless: the structure it
+// used to define is now defined in "location.hh".
+//
+// To get rid of this file:
+// 1. add 'require "3.2"' (or newer) to your grammar file
+// 2. remove references to this file from your build system
+// 3. if you used to include it, include "location.hh" instead.
+
+#include "location.hh"
-// Generated 201811151407
-// A Bison parser, made by GNU Bison 3.0.5.
-
-// Stack handling for Bison parsers in C++
-
-// Copyright (C) 2002-2015, 2018 Free Software Foundation, Inc.
-
-// This program is free software: you can redistribute it and/or modify
-// it under the terms of the GNU General Public License as published by
-// the Free Software Foundation, either version 3 of the License, or
-// (at your option) any later version.
-
-// This program is distributed in the hope that it will be useful,
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-// GNU General Public License for more details.
-
-// You should have received a copy of the GNU General Public License
-// along with this program. If not, see <http://www.gnu.org/licenses/>.
-
-// As a special exception, you may create a larger work that contains
-// part or all of the Bison parser skeleton and distribute that work
-// under terms of your choice, so long as that work isn't itself a
-// parser generator using the skeleton or a modified version thereof
-// as a parser skeleton. Alternatively, if you modify or redistribute
-// the parser skeleton itself, you may (at your option) remove this
-// special exception, which will cause the skeleton and the resulting
-// Bison output files to be licensed under the GNU General Public
-// License without this special exception.
-
-// This special exception was added by the Free Software Foundation in
-// version 2.2 of Bison.
-
-/**
- ** \file stack.hh
- ** Define the isc::dhcp::stack class.
- */
-
-#ifndef YY_PARSER4_STACK_HH_INCLUDED
-# define YY_PARSER4_STACK_HH_INCLUDED
-
-# include <vector>
-
-#line 14 "dhcp4_parser.yy" // stack.hh:131
-namespace isc { namespace dhcp {
-#line 46 "stack.hh" // stack.hh:131
- /// A stack with random access from its top.
- template <class T, class S = std::vector<T> >
- class stack
- {
- public:
- // Hide our reversed order.
- typedef typename S::reverse_iterator iterator;
- typedef typename S::const_reverse_iterator const_iterator;
-
- stack ()
- : seq_ ()
- {
- seq_.reserve (200);
- }
-
- stack (unsigned n)
- : seq_ (n)
- {}
-
- /// Random access.
- ///
- /// Index 0 returns the topmost element.
- T&
- operator[] (unsigned i)
- {
- return seq_[seq_.size () - 1 - i];
- }
-
- /// Random access.
- ///
- /// Index 0 returns the topmost element.
- const T&
- operator[] (unsigned i) const
- {
- return seq_[seq_.size () - 1 - i];
- }
-
- /// Steal the contents of \a t.
- ///
- /// Close to move-semantics.
- void
- push (T& t)
- {
- seq_.push_back (T());
- operator[](0).move (t);
- }
-
- void
- pop (unsigned n = 1)
- {
- for (; n; --n)
- seq_.pop_back ();
- }
-
- void
- clear ()
- {
- seq_.clear ();
- }
-
- typename S::size_type
- size () const
- {
- return seq_.size ();
- }
-
- const_iterator
- begin () const
- {
- return seq_.rbegin ();
- }
-
- const_iterator
- end () const
- {
- return seq_.rend ();
- }
-
- private:
- stack (const stack&);
- stack& operator= (const stack&);
- /// The wrapped container.
- S seq_;
- };
-
- /// Present a slice of the top of a stack.
- template <class T, class S = stack<T> >
- class slice
- {
- public:
- slice (const S& stack, unsigned range)
- : stack_ (stack)
- , range_ (range)
- {}
-
- const T&
- operator [] (unsigned i) const
- {
- return stack_[range_ - i];
- }
-
- private:
- const S& stack_;
- unsigned range_;
- };
-
-#line 14 "dhcp4_parser.yy" // stack.hh:131
-} } // isc::dhcp
-#line 155 "stack.hh" // stack.hh:131
-
-#endif // !YY_PARSER4_STACK_HH_INCLUDED
+// Generated 201811172153
+// A Bison parser, made by GNU Bison 3.2.1.
+
+// Starting with Bison 3.2, this file is useless: the structure it
+// used to define is now defined with the parser itself.
+//
+// To get rid of this file:
+// 1. add 'require "3.2"' (or newer) to your grammar file
+// 2. remove references to this file from your build system.
-// A Bison parser, made by GNU Bison 3.0.5.
+// A Bison parser, made by GNU Bison 3.2.1.
// Skeleton implementation for Bison LALR(1) parsers in C++
// This special exception was added by the Free Software Foundation in
// version 2.2 of Bison.
+// Undocumented macros, especially those whose name start with YY_,
+// are private implementation details. Do not rely on them.
+
+
// Take the name prefix into account.
#define yylex parser6_lex
-// First part of user declarations.
-#line 39 "dhcp6_parser.cc" // lalr1.cc:406
-
-# ifndef YY_NULLPTR
-# if defined __cplusplus && 201103L <= __cplusplus
-# define YY_NULLPTR nullptr
-# else
-# define YY_NULLPTR 0
-# endif
-# endif
#include "dhcp6_parser.h"
-// User implementation prologue.
-#line 53 "dhcp6_parser.cc" // lalr1.cc:414
// Unqualified %code blocks.
-#line 34 "dhcp6_parser.yy" // lalr1.cc:415
+#line 34 "dhcp6_parser.yy" // lalr1.cc:438
#include <dhcp6/parser_context.h>
-#line 59 "dhcp6_parser.cc" // lalr1.cc:415
+#line 51 "dhcp6_parser.cc" // lalr1.cc:438
#ifndef YY_
# endif
#endif
+// Whether we are compiled with exception support.
+#ifndef YY_EXCEPTIONS
+# if defined __GNUC__ && !defined __EXCEPTIONS
+# define YY_EXCEPTIONS 0
+# else
+# define YY_EXCEPTIONS 1
+# endif
+#endif
+
#define YYRHSLOC(Rhs, K) ((Rhs)[K].location)
/* YYLLOC_DEFAULT -- Set CURRENT to span from RHS[1] to RHS[N].
If N is 0, then set CURRENT to the empty location which ends
#define YYERROR goto yyerrorlab
#define YYRECOVERING() (!!yyerrstatus_)
-#line 14 "dhcp6_parser.yy" // lalr1.cc:481
+#line 14 "dhcp6_parser.yy" // lalr1.cc:513
namespace isc { namespace dhcp {
-#line 145 "dhcp6_parser.cc" // lalr1.cc:481
+#line 146 "dhcp6_parser.cc" // lalr1.cc:513
/* Return YYSTR after stripping away unnecessary quotes and
backslashes, so that it's suitable for yyerror. The heuristic is
Dhcp6Parser::stack_symbol_type::stack_symbol_type ()
{}
- Dhcp6Parser::stack_symbol_type::stack_symbol_type (const stack_symbol_type& that)
- : super_type (that.state, that.location)
+ Dhcp6Parser::stack_symbol_type::stack_symbol_type (YY_RVREF (stack_symbol_type) that)
+ : super_type (YY_MOVE (that.state), YY_MOVE (that.location))
{
switch (that.type_get ())
{
case 473: // duid_type
case 508: // ncr_protocol_value
case 516: // replace_client_name_value
- value.copy< ElementPtr > (that.value);
+ value.YY_MOVE_OR_COPY< ElementPtr > (YY_MOVE (that.value));
break;
case 174: // "boolean"
- value.copy< bool > (that.value);
+ value.YY_MOVE_OR_COPY< bool > (YY_MOVE (that.value));
break;
case 173: // "floating point"
- value.copy< double > (that.value);
+ value.YY_MOVE_OR_COPY< double > (YY_MOVE (that.value));
break;
case 172: // "integer"
- value.copy< int64_t > (that.value);
+ value.YY_MOVE_OR_COPY< int64_t > (YY_MOVE (that.value));
break;
case 171: // "constant string"
- value.copy< std::string > (that.value);
+ value.YY_MOVE_OR_COPY< std::string > (YY_MOVE (that.value));
break;
default:
break;
}
+#if defined __cplusplus && 201103L <= __cplusplus
+ // that is emptied.
+ that.state = empty_state;
+#endif
}
- Dhcp6Parser::stack_symbol_type::stack_symbol_type (state_type s, symbol_type& that)
- : super_type (s, that.location)
+ Dhcp6Parser::stack_symbol_type::stack_symbol_type (state_type s, YY_MOVE_REF (symbol_type) that)
+ : super_type (s, YY_MOVE (that.location))
{
switch (that.type_get ())
{
case 473: // duid_type
case 508: // ncr_protocol_value
case 516: // replace_client_name_value
- value.move< ElementPtr > (that.value);
+ value.move< ElementPtr > (YY_MOVE (that.value));
break;
case 174: // "boolean"
- value.move< bool > (that.value);
+ value.move< bool > (YY_MOVE (that.value));
break;
case 173: // "floating point"
- value.move< double > (that.value);
+ value.move< double > (YY_MOVE (that.value));
break;
case 172: // "integer"
- value.move< int64_t > (that.value);
+ value.move< int64_t > (YY_MOVE (that.value));
break;
case 171: // "constant string"
- value.move< std::string > (that.value);
+ value.move< std::string > (YY_MOVE (that.value));
break;
default:
that.type = empty_symbol;
}
+#if !defined __cplusplus || __cplusplus < 201103L
Dhcp6Parser::stack_symbol_type&
- Dhcp6Parser::stack_symbol_type::operator= (const stack_symbol_type& that)
+ Dhcp6Parser::stack_symbol_type::operator= (stack_symbol_type& that)
{
state = that.state;
switch (that.type_get ())
case 473: // duid_type
case 508: // ncr_protocol_value
case 516: // replace_client_name_value
- value.copy< ElementPtr > (that.value);
+ value.move< ElementPtr > (that.value);
break;
case 174: // "boolean"
- value.copy< bool > (that.value);
+ value.move< bool > (that.value);
break;
case 173: // "floating point"
- value.copy< double > (that.value);
+ value.move< double > (that.value);
break;
case 172: // "integer"
- value.copy< int64_t > (that.value);
+ value.move< int64_t > (that.value);
break;
case 171: // "constant string"
- value.copy< std::string > (that.value);
+ value.move< std::string > (that.value);
break;
default:
}
location = that.location;
+ // that is emptied.
+ that.state = empty_state;
return *this;
}
-
+#endif
template <typename Base>
void
{
case 171: // "constant string"
-#line 249 "dhcp6_parser.yy" // lalr1.cc:635
+#line 249 "dhcp6_parser.yy" // lalr1.cc:672
{ yyoutput << yysym.value.template as< std::string > (); }
-#line 390 "dhcp6_parser.cc" // lalr1.cc:635
+#line 398 "dhcp6_parser.cc" // lalr1.cc:672
break;
case 172: // "integer"
-#line 249 "dhcp6_parser.yy" // lalr1.cc:635
+#line 249 "dhcp6_parser.yy" // lalr1.cc:672
{ yyoutput << yysym.value.template as< int64_t > (); }
-#line 397 "dhcp6_parser.cc" // lalr1.cc:635
+#line 405 "dhcp6_parser.cc" // lalr1.cc:672
break;
case 173: // "floating point"
-#line 249 "dhcp6_parser.yy" // lalr1.cc:635
+#line 249 "dhcp6_parser.yy" // lalr1.cc:672
{ yyoutput << yysym.value.template as< double > (); }
-#line 404 "dhcp6_parser.cc" // lalr1.cc:635
+#line 412 "dhcp6_parser.cc" // lalr1.cc:672
break;
case 174: // "boolean"
-#line 249 "dhcp6_parser.yy" // lalr1.cc:635
+#line 249 "dhcp6_parser.yy" // lalr1.cc:672
{ yyoutput << yysym.value.template as< bool > (); }
-#line 411 "dhcp6_parser.cc" // lalr1.cc:635
+#line 419 "dhcp6_parser.cc" // lalr1.cc:672
break;
case 192: // value
-#line 249 "dhcp6_parser.yy" // lalr1.cc:635
+#line 249 "dhcp6_parser.yy" // lalr1.cc:672
{ yyoutput << yysym.value.template as< ElementPtr > (); }
-#line 418 "dhcp6_parser.cc" // lalr1.cc:635
+#line 426 "dhcp6_parser.cc" // lalr1.cc:672
break;
case 196: // map_value
-#line 249 "dhcp6_parser.yy" // lalr1.cc:635
+#line 249 "dhcp6_parser.yy" // lalr1.cc:672
{ yyoutput << yysym.value.template as< ElementPtr > (); }
-#line 425 "dhcp6_parser.cc" // lalr1.cc:635
+#line 433 "dhcp6_parser.cc" // lalr1.cc:672
break;
case 248: // db_type
-#line 249 "dhcp6_parser.yy" // lalr1.cc:635
+#line 249 "dhcp6_parser.yy" // lalr1.cc:672
{ yyoutput << yysym.value.template as< ElementPtr > (); }
-#line 432 "dhcp6_parser.cc" // lalr1.cc:635
+#line 440 "dhcp6_parser.cc" // lalr1.cc:672
break;
case 337: // hr_mode
-#line 249 "dhcp6_parser.yy" // lalr1.cc:635
+#line 249 "dhcp6_parser.yy" // lalr1.cc:672
{ yyoutput << yysym.value.template as< ElementPtr > (); }
-#line 439 "dhcp6_parser.cc" // lalr1.cc:635
+#line 447 "dhcp6_parser.cc" // lalr1.cc:672
break;
case 473: // duid_type
-#line 249 "dhcp6_parser.yy" // lalr1.cc:635
+#line 249 "dhcp6_parser.yy" // lalr1.cc:672
{ yyoutput << yysym.value.template as< ElementPtr > (); }
-#line 446 "dhcp6_parser.cc" // lalr1.cc:635
+#line 454 "dhcp6_parser.cc" // lalr1.cc:672
break;
case 508: // ncr_protocol_value
-#line 249 "dhcp6_parser.yy" // lalr1.cc:635
+#line 249 "dhcp6_parser.yy" // lalr1.cc:672
{ yyoutput << yysym.value.template as< ElementPtr > (); }
-#line 453 "dhcp6_parser.cc" // lalr1.cc:635
+#line 461 "dhcp6_parser.cc" // lalr1.cc:672
break;
case 516: // replace_client_name_value
-#line 249 "dhcp6_parser.yy" // lalr1.cc:635
+#line 249 "dhcp6_parser.yy" // lalr1.cc:672
{ yyoutput << yysym.value.template as< ElementPtr > (); }
-#line 460 "dhcp6_parser.cc" // lalr1.cc:635
+#line 468 "dhcp6_parser.cc" // lalr1.cc:672
break;
#endif
void
- Dhcp6Parser::yypush_ (const char* m, state_type s, symbol_type& sym)
+ Dhcp6Parser::yypush_ (const char* m, YY_MOVE_REF (stack_symbol_type) sym)
{
- stack_symbol_type t (s, sym);
- yypush_ (m, t);
+ if (m)
+ YY_SYMBOL_PRINT (m, sym);
+ yystack_.push (YY_MOVE (sym));
}
void
- Dhcp6Parser::yypush_ (const char* m, stack_symbol_type& s)
+ Dhcp6Parser::yypush_ (const char* m, state_type s, YY_MOVE_REF (symbol_type) sym)
{
- if (m)
- YY_SYMBOL_PRINT (m, s);
- yystack_.push (s);
+#if defined __cplusplus && 201103L <= __cplusplus
+ yypush_ (m, stack_symbol_type (s, std::move (sym)));
+#else
+ stack_symbol_type ss (s, sym);
+ yypush_ (m, ss);
+#endif
}
void
- Dhcp6Parser::yypop_ (unsigned n)
+ Dhcp6Parser::yypop_ (int n)
{
yystack_.pop (n);
}
return yyvalue == yytable_ninf_;
}
+ int
+ Dhcp6Parser::operator() ()
+ {
+ return parse ();
+ }
+
int
Dhcp6Parser::parse ()
{
/// The return value of parse ().
int yyresult;
- // FIXME: This shoud be completely indented. It is not yet to
- // avoid gratuitous conflicts when merging into the master branch.
+#if YY_EXCEPTIONS
try
+#endif // YY_EXCEPTIONS
{
YYCDEBUG << "Starting parse\n";
location values to have been already stored, initialize these
stacks with a primary value. */
yystack_.clear ();
- yypush_ (YY_NULLPTR, 0, yyla);
+ yypush_ (YY_NULLPTR, 0, YY_MOVE (yyla));
// A new symbol was pushed on the stack.
yynewstate:
// Backup.
yybackup:
-
// Try to take a decision without lookahead.
yyn = yypact_[yystack_[0].state];
if (yy_pact_value_is_default_ (yyn))
if (yyla.empty ())
{
YYCDEBUG << "Reading a token: ";
+#if YY_EXCEPTIONS
try
+#endif // YY_EXCEPTIONS
{
symbol_type yylookahead (yylex (ctx));
yyla.move (yylookahead);
}
+#if YY_EXCEPTIONS
catch (const syntax_error& yyexc)
{
error (yyexc);
goto yyerrlab1;
}
+#endif // YY_EXCEPTIONS
}
YY_SYMBOL_PRINT ("Next token is", yyla);
--yyerrstatus_;
// Shift the lookahead token.
- yypush_ ("Shifting", yyn, yyla);
+ yypush_ ("Shifting", yyn, YY_MOVE (yyla));
goto yynewstate;
/*-----------------------------------------------------------.
case 473: // duid_type
case 508: // ncr_protocol_value
case 516: // replace_client_name_value
- yylhs.value.build< ElementPtr > ();
+ yylhs.value.emplace< ElementPtr > ();
break;
case 174: // "boolean"
- yylhs.value.build< bool > ();
+ yylhs.value.emplace< bool > ();
break;
case 173: // "floating point"
- yylhs.value.build< double > ();
+ yylhs.value.emplace< double > ();
break;
case 172: // "integer"
- yylhs.value.build< int64_t > ();
+ yylhs.value.emplace< int64_t > ();
break;
case 171: // "constant string"
- yylhs.value.build< std::string > ();
+ yylhs.value.emplace< std::string > ();
break;
default:
// Perform the reduction.
YY_REDUCE_PRINT (yyn);
+#if YY_EXCEPTIONS
try
+#endif // YY_EXCEPTIONS
{
switch (yyn)
{
case 2:
-#line 258 "dhcp6_parser.yy" // lalr1.cc:856
+#line 258 "dhcp6_parser.yy" // lalr1.cc:907
{ ctx.ctx_ = ctx.NO_KEYWORD; }
-#line 704 "dhcp6_parser.cc" // lalr1.cc:856
+#line 727 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 4:
-#line 259 "dhcp6_parser.yy" // lalr1.cc:856
+#line 259 "dhcp6_parser.yy" // lalr1.cc:907
{ ctx.ctx_ = ctx.CONFIG; }
-#line 710 "dhcp6_parser.cc" // lalr1.cc:856
+#line 733 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 6:
-#line 260 "dhcp6_parser.yy" // lalr1.cc:856
+#line 260 "dhcp6_parser.yy" // lalr1.cc:907
{ ctx.ctx_ = ctx.DHCP6; }
-#line 716 "dhcp6_parser.cc" // lalr1.cc:856
+#line 739 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 8:
-#line 261 "dhcp6_parser.yy" // lalr1.cc:856
+#line 261 "dhcp6_parser.yy" // lalr1.cc:907
{ ctx.ctx_ = ctx.INTERFACES_CONFIG; }
-#line 722 "dhcp6_parser.cc" // lalr1.cc:856
+#line 745 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 10:
-#line 262 "dhcp6_parser.yy" // lalr1.cc:856
+#line 262 "dhcp6_parser.yy" // lalr1.cc:907
{ ctx.ctx_ = ctx.SUBNET6; }
-#line 728 "dhcp6_parser.cc" // lalr1.cc:856
+#line 751 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 12:
-#line 263 "dhcp6_parser.yy" // lalr1.cc:856
+#line 263 "dhcp6_parser.yy" // lalr1.cc:907
{ ctx.ctx_ = ctx.POOLS; }
-#line 734 "dhcp6_parser.cc" // lalr1.cc:856
+#line 757 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 14:
-#line 264 "dhcp6_parser.yy" // lalr1.cc:856
+#line 264 "dhcp6_parser.yy" // lalr1.cc:907
{ ctx.ctx_ = ctx.PD_POOLS; }
-#line 740 "dhcp6_parser.cc" // lalr1.cc:856
+#line 763 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 16:
-#line 265 "dhcp6_parser.yy" // lalr1.cc:856
+#line 265 "dhcp6_parser.yy" // lalr1.cc:907
{ ctx.ctx_ = ctx.RESERVATIONS; }
-#line 746 "dhcp6_parser.cc" // lalr1.cc:856
+#line 769 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 18:
-#line 266 "dhcp6_parser.yy" // lalr1.cc:856
+#line 266 "dhcp6_parser.yy" // lalr1.cc:907
{ ctx.ctx_ = ctx.DHCP6; }
-#line 752 "dhcp6_parser.cc" // lalr1.cc:856
+#line 775 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 20:
-#line 267 "dhcp6_parser.yy" // lalr1.cc:856
+#line 267 "dhcp6_parser.yy" // lalr1.cc:907
{ ctx.ctx_ = ctx.OPTION_DEF; }
-#line 758 "dhcp6_parser.cc" // lalr1.cc:856
+#line 781 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 22:
-#line 268 "dhcp6_parser.yy" // lalr1.cc:856
+#line 268 "dhcp6_parser.yy" // lalr1.cc:907
{ ctx.ctx_ = ctx.OPTION_DATA; }
-#line 764 "dhcp6_parser.cc" // lalr1.cc:856
+#line 787 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 24:
-#line 269 "dhcp6_parser.yy" // lalr1.cc:856
+#line 269 "dhcp6_parser.yy" // lalr1.cc:907
{ ctx.ctx_ = ctx.HOOKS_LIBRARIES; }
-#line 770 "dhcp6_parser.cc" // lalr1.cc:856
+#line 793 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 26:
-#line 270 "dhcp6_parser.yy" // lalr1.cc:856
+#line 270 "dhcp6_parser.yy" // lalr1.cc:907
{ ctx.ctx_ = ctx.DHCP_DDNS; }
-#line 776 "dhcp6_parser.cc" // lalr1.cc:856
+#line 799 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 28:
-#line 271 "dhcp6_parser.yy" // lalr1.cc:856
+#line 271 "dhcp6_parser.yy" // lalr1.cc:907
{ ctx.ctx_ = ctx.LOGGING; }
-#line 782 "dhcp6_parser.cc" // lalr1.cc:856
+#line 805 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 30:
-#line 272 "dhcp6_parser.yy" // lalr1.cc:856
+#line 272 "dhcp6_parser.yy" // lalr1.cc:907
{ ctx.ctx_ = ctx.CONFIG_CONTROL; }
-#line 788 "dhcp6_parser.cc" // lalr1.cc:856
+#line 811 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 32:
-#line 280 "dhcp6_parser.yy" // lalr1.cc:856
+#line 280 "dhcp6_parser.yy" // lalr1.cc:907
{ yylhs.value.as< ElementPtr > () = ElementPtr(new IntElement(yystack_[0].value.as< int64_t > (), ctx.loc2pos(yystack_[0].location))); }
-#line 794 "dhcp6_parser.cc" // lalr1.cc:856
+#line 817 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 33:
-#line 281 "dhcp6_parser.yy" // lalr1.cc:856
+#line 281 "dhcp6_parser.yy" // lalr1.cc:907
{ yylhs.value.as< ElementPtr > () = ElementPtr(new DoubleElement(yystack_[0].value.as< double > (), ctx.loc2pos(yystack_[0].location))); }
-#line 800 "dhcp6_parser.cc" // lalr1.cc:856
+#line 823 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 34:
-#line 282 "dhcp6_parser.yy" // lalr1.cc:856
+#line 282 "dhcp6_parser.yy" // lalr1.cc:907
{ yylhs.value.as< ElementPtr > () = ElementPtr(new BoolElement(yystack_[0].value.as< bool > (), ctx.loc2pos(yystack_[0].location))); }
-#line 806 "dhcp6_parser.cc" // lalr1.cc:856
+#line 829 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 35:
-#line 283 "dhcp6_parser.yy" // lalr1.cc:856
+#line 283 "dhcp6_parser.yy" // lalr1.cc:907
{ yylhs.value.as< ElementPtr > () = ElementPtr(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location))); }
-#line 812 "dhcp6_parser.cc" // lalr1.cc:856
+#line 835 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 36:
-#line 284 "dhcp6_parser.yy" // lalr1.cc:856
+#line 284 "dhcp6_parser.yy" // lalr1.cc:907
{ yylhs.value.as< ElementPtr > () = ElementPtr(new NullElement(ctx.loc2pos(yystack_[0].location))); }
-#line 818 "dhcp6_parser.cc" // lalr1.cc:856
+#line 841 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 37:
-#line 285 "dhcp6_parser.yy" // lalr1.cc:856
+#line 285 "dhcp6_parser.yy" // lalr1.cc:907
{ yylhs.value.as< ElementPtr > () = ctx.stack_.back(); ctx.stack_.pop_back(); }
-#line 824 "dhcp6_parser.cc" // lalr1.cc:856
+#line 847 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 38:
-#line 286 "dhcp6_parser.yy" // lalr1.cc:856
+#line 286 "dhcp6_parser.yy" // lalr1.cc:907
{ yylhs.value.as< ElementPtr > () = ctx.stack_.back(); ctx.stack_.pop_back(); }
-#line 830 "dhcp6_parser.cc" // lalr1.cc:856
+#line 853 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 39:
-#line 289 "dhcp6_parser.yy" // lalr1.cc:856
+#line 289 "dhcp6_parser.yy" // lalr1.cc:907
{
// Push back the JSON value on the stack
ctx.stack_.push_back(yystack_[0].value.as< ElementPtr > ());
}
-#line 839 "dhcp6_parser.cc" // lalr1.cc:856
+#line 862 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 40:
-#line 294 "dhcp6_parser.yy" // lalr1.cc:856
+#line 294 "dhcp6_parser.yy" // lalr1.cc:907
{
// This code is executed when we're about to start parsing
// the content of the map
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.push_back(m);
}
-#line 850 "dhcp6_parser.cc" // lalr1.cc:856
+#line 873 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 41:
-#line 299 "dhcp6_parser.yy" // lalr1.cc:856
+#line 299 "dhcp6_parser.yy" // lalr1.cc:907
{
// map parsing completed. If we ever want to do any wrap up
// (maybe some sanity checking), this would be the best place
// for it.
}
-#line 860 "dhcp6_parser.cc" // lalr1.cc:856
+#line 883 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 42:
-#line 305 "dhcp6_parser.yy" // lalr1.cc:856
+#line 305 "dhcp6_parser.yy" // lalr1.cc:907
{ yylhs.value.as< ElementPtr > () = ctx.stack_.back(); ctx.stack_.pop_back(); }
-#line 866 "dhcp6_parser.cc" // lalr1.cc:856
+#line 889 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 45:
-#line 312 "dhcp6_parser.yy" // lalr1.cc:856
+#line 312 "dhcp6_parser.yy" // lalr1.cc:907
{
// map containing a single entry
ctx.stack_.back()->set(yystack_[2].value.as< std::string > (), yystack_[0].value.as< ElementPtr > ());
}
-#line 875 "dhcp6_parser.cc" // lalr1.cc:856
+#line 898 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 46:
-#line 316 "dhcp6_parser.yy" // lalr1.cc:856
+#line 316 "dhcp6_parser.yy" // lalr1.cc:907
{
// map consisting of a shorter map followed by
// comma and string:value
ctx.stack_.back()->set(yystack_[2].value.as< std::string > (), yystack_[0].value.as< ElementPtr > ());
}
-#line 885 "dhcp6_parser.cc" // lalr1.cc:856
+#line 908 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 47:
-#line 323 "dhcp6_parser.yy" // lalr1.cc:856
+#line 323 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr l(new ListElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.push_back(l);
}
-#line 894 "dhcp6_parser.cc" // lalr1.cc:856
+#line 917 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 48:
-#line 326 "dhcp6_parser.yy" // lalr1.cc:856
+#line 326 "dhcp6_parser.yy" // lalr1.cc:907
{
// list parsing complete. Put any sanity checking here
}
-#line 902 "dhcp6_parser.cc" // lalr1.cc:856
+#line 925 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 51:
-#line 334 "dhcp6_parser.yy" // lalr1.cc:856
+#line 334 "dhcp6_parser.yy" // lalr1.cc:907
{
// List consisting of a single element.
ctx.stack_.back()->add(yystack_[0].value.as< ElementPtr > ());
}
-#line 911 "dhcp6_parser.cc" // lalr1.cc:856
+#line 934 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 52:
-#line 338 "dhcp6_parser.yy" // lalr1.cc:856
+#line 338 "dhcp6_parser.yy" // lalr1.cc:907
{
// List ending with , and a value.
ctx.stack_.back()->add(yystack_[0].value.as< ElementPtr > ());
}
-#line 920 "dhcp6_parser.cc" // lalr1.cc:856
+#line 943 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 53:
-#line 345 "dhcp6_parser.yy" // lalr1.cc:856
+#line 345 "dhcp6_parser.yy" // lalr1.cc:907
{
// List parsing about to start
}
-#line 928 "dhcp6_parser.cc" // lalr1.cc:856
+#line 951 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 54:
-#line 347 "dhcp6_parser.yy" // lalr1.cc:856
+#line 347 "dhcp6_parser.yy" // lalr1.cc:907
{
// list parsing complete. Put any sanity checking here
//ctx.stack_.pop_back();
}
-#line 937 "dhcp6_parser.cc" // lalr1.cc:856
+#line 960 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 57:
-#line 356 "dhcp6_parser.yy" // lalr1.cc:856
+#line 356 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr s(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->add(s);
}
-#line 946 "dhcp6_parser.cc" // lalr1.cc:856
+#line 969 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 58:
-#line 360 "dhcp6_parser.yy" // lalr1.cc:856
+#line 360 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr s(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->add(s);
}
-#line 955 "dhcp6_parser.cc" // lalr1.cc:856
+#line 978 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 59:
-#line 371 "dhcp6_parser.yy" // lalr1.cc:856
+#line 371 "dhcp6_parser.yy" // lalr1.cc:907
{
const std::string& where = ctx.contextName();
const std::string& keyword = yystack_[1].value.as< std::string > ();
error(yystack_[1].location,
"got unexpected keyword \"" + keyword + "\" in " + where + " map.");
}
-#line 966 "dhcp6_parser.cc" // lalr1.cc:856
+#line 989 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 60:
-#line 381 "dhcp6_parser.yy" // lalr1.cc:856
+#line 381 "dhcp6_parser.yy" // lalr1.cc:907
{
// This code is executed when we're about to start parsing
// the content of the map
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.push_back(m);
}
-#line 977 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1000 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 61:
-#line 386 "dhcp6_parser.yy" // lalr1.cc:856
+#line 386 "dhcp6_parser.yy" // lalr1.cc:907
{
// map parsing completed. If we ever want to do any wrap up
// (maybe some sanity checking), this would be the best place
// Dhcp6 is required
ctx.require("Dhcp6", ctx.loc2pos(yystack_[3].location), ctx.loc2pos(yystack_[0].location));
}
-#line 990 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1013 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 70:
-#line 409 "dhcp6_parser.yy" // lalr1.cc:856
+#line 409 "dhcp6_parser.yy" // lalr1.cc:907
{
// This code is executed when we're about to start parsing
// the content of the map
ctx.stack_.push_back(m);
ctx.enter(ctx.DHCP6);
}
-#line 1003 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1026 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 71:
-#line 416 "dhcp6_parser.yy" // lalr1.cc:856
+#line 416 "dhcp6_parser.yy" // lalr1.cc:907
{
// No global parameter is required
ctx.stack_.pop_back();
ctx.leave();
}
-#line 1013 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1036 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 72:
-#line 424 "dhcp6_parser.yy" // lalr1.cc:856
+#line 424 "dhcp6_parser.yy" // lalr1.cc:907
{
// Parse the Dhcp6 map
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.push_back(m);
}
-#line 1023 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1046 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 73:
-#line 428 "dhcp6_parser.yy" // lalr1.cc:856
+#line 428 "dhcp6_parser.yy" // lalr1.cc:907
{
// No global parameter is required
// parsing completed
}
-#line 1032 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1055 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 107:
-#line 472 "dhcp6_parser.yy" // lalr1.cc:856
+#line 472 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr prf(new IntElement(yystack_[0].value.as< int64_t > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("preferred-lifetime", prf);
}
-#line 1041 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1064 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 108:
-#line 477 "dhcp6_parser.yy" // lalr1.cc:856
+#line 477 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr prf(new IntElement(yystack_[0].value.as< int64_t > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("valid-lifetime", prf);
}
-#line 1050 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1073 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 109:
-#line 482 "dhcp6_parser.yy" // lalr1.cc:856
+#line 482 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr prf(new IntElement(yystack_[0].value.as< int64_t > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("renew-timer", prf);
}
-#line 1059 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1082 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 110:
-#line 487 "dhcp6_parser.yy" // lalr1.cc:856
+#line 487 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr prf(new IntElement(yystack_[0].value.as< int64_t > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("rebind-timer", prf);
}
-#line 1068 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1091 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 111:
-#line 492 "dhcp6_parser.yy" // lalr1.cc:856
+#line 492 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr dpp(new IntElement(yystack_[0].value.as< int64_t > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("decline-probation-period", dpp);
}
-#line 1077 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1100 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 112:
-#line 497 "dhcp6_parser.yy" // lalr1.cc:856
+#line 497 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 1085 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1108 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 113:
-#line 499 "dhcp6_parser.yy" // lalr1.cc:856
+#line 499 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr stag(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("server-tag", stag);
ctx.leave();
}
-#line 1095 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1118 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 114:
-#line 505 "dhcp6_parser.yy" // lalr1.cc:856
+#line 505 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr i(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("interfaces-config", i);
ctx.stack_.push_back(i);
ctx.enter(ctx.INTERFACES_CONFIG);
}
-#line 1106 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1129 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 115:
-#line 510 "dhcp6_parser.yy" // lalr1.cc:856
+#line 510 "dhcp6_parser.yy" // lalr1.cc:907
{
// No interfaces config param is required
ctx.stack_.pop_back();
ctx.leave();
}
-#line 1116 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1139 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 116:
-#line 516 "dhcp6_parser.yy" // lalr1.cc:856
+#line 516 "dhcp6_parser.yy" // lalr1.cc:907
{
// Parse the interfaces-config map
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.push_back(m);
}
-#line 1126 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1149 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 117:
-#line 520 "dhcp6_parser.yy" // lalr1.cc:856
+#line 520 "dhcp6_parser.yy" // lalr1.cc:907
{
// No interfaces config param is required
// parsing completed
}
-#line 1135 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1158 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 125:
-#line 536 "dhcp6_parser.yy" // lalr1.cc:856
+#line 536 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr l(new ListElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("interfaces", l);
ctx.stack_.push_back(l);
ctx.enter(ctx.NO_KEYWORD);
}
-#line 1146 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1169 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 126:
-#line 541 "dhcp6_parser.yy" // lalr1.cc:856
+#line 541 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
ctx.leave();
}
-#line 1155 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1178 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 127:
-#line 546 "dhcp6_parser.yy" // lalr1.cc:856
+#line 546 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr b(new BoolElement(yystack_[0].value.as< bool > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("re-detect", b);
}
-#line 1164 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1187 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 128:
-#line 552 "dhcp6_parser.yy" // lalr1.cc:856
+#line 552 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr i(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("lease-database", i);
ctx.stack_.push_back(i);
ctx.enter(ctx.LEASE_DATABASE);
}
-#line 1175 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1198 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 129:
-#line 557 "dhcp6_parser.yy" // lalr1.cc:856
+#line 557 "dhcp6_parser.yy" // lalr1.cc:907
{
// The type parameter is required
ctx.require("type", ctx.loc2pos(yystack_[2].location), ctx.loc2pos(yystack_[0].location));
ctx.stack_.pop_back();
ctx.leave();
}
-#line 1186 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1209 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 130:
-#line 564 "dhcp6_parser.yy" // lalr1.cc:856
+#line 564 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr i(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("hosts-database", i);
ctx.stack_.push_back(i);
ctx.enter(ctx.HOSTS_DATABASE);
}
-#line 1197 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1220 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 131:
-#line 569 "dhcp6_parser.yy" // lalr1.cc:856
+#line 569 "dhcp6_parser.yy" // lalr1.cc:907
{
// The type parameter is required
ctx.require("type", ctx.loc2pos(yystack_[2].location), ctx.loc2pos(yystack_[0].location));
ctx.stack_.pop_back();
ctx.leave();
}
-#line 1208 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1231 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 132:
-#line 576 "dhcp6_parser.yy" // lalr1.cc:856
+#line 576 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr l(new ListElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("hosts-databases", l);
ctx.stack_.push_back(l);
ctx.enter(ctx.HOSTS_DATABASE);
}
-#line 1219 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1242 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 133:
-#line 581 "dhcp6_parser.yy" // lalr1.cc:856
+#line 581 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
ctx.leave();
}
-#line 1228 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1251 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 138:
-#line 594 "dhcp6_parser.yy" // lalr1.cc:856
+#line 594 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->add(m);
ctx.stack_.push_back(m);
}
-#line 1238 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1261 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 139:
-#line 598 "dhcp6_parser.yy" // lalr1.cc:856
+#line 598 "dhcp6_parser.yy" // lalr1.cc:907
{
// The type parameter is required
ctx.require("type", ctx.loc2pos(yystack_[3].location), ctx.loc2pos(yystack_[0].location));
ctx.stack_.pop_back();
}
-#line 1248 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1271 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 160:
-#line 628 "dhcp6_parser.yy" // lalr1.cc:856
+#line 628 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.DATABASE_TYPE);
}
-#line 1256 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1279 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 161:
-#line 630 "dhcp6_parser.yy" // lalr1.cc:856
+#line 630 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.stack_.back()->set("type", yystack_[0].value.as< ElementPtr > ());
ctx.leave();
}
-#line 1265 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1288 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 162:
-#line 635 "dhcp6_parser.yy" // lalr1.cc:856
+#line 635 "dhcp6_parser.yy" // lalr1.cc:907
{ yylhs.value.as< ElementPtr > () = ElementPtr(new StringElement("memfile", ctx.loc2pos(yystack_[0].location))); }
-#line 1271 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1294 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 163:
-#line 636 "dhcp6_parser.yy" // lalr1.cc:856
+#line 636 "dhcp6_parser.yy" // lalr1.cc:907
{ yylhs.value.as< ElementPtr > () = ElementPtr(new StringElement("mysql", ctx.loc2pos(yystack_[0].location))); }
-#line 1277 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1300 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 164:
-#line 637 "dhcp6_parser.yy" // lalr1.cc:856
+#line 637 "dhcp6_parser.yy" // lalr1.cc:907
{ yylhs.value.as< ElementPtr > () = ElementPtr(new StringElement("postgresql", ctx.loc2pos(yystack_[0].location))); }
-#line 1283 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1306 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 165:
-#line 638 "dhcp6_parser.yy" // lalr1.cc:856
+#line 638 "dhcp6_parser.yy" // lalr1.cc:907
{ yylhs.value.as< ElementPtr > () = ElementPtr(new StringElement("cql", ctx.loc2pos(yystack_[0].location))); }
-#line 1289 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1312 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 166:
-#line 641 "dhcp6_parser.yy" // lalr1.cc:856
+#line 641 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 1297 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1320 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 167:
-#line 643 "dhcp6_parser.yy" // lalr1.cc:856
+#line 643 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr user(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("user", user);
ctx.leave();
}
-#line 1307 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1330 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 168:
-#line 649 "dhcp6_parser.yy" // lalr1.cc:856
+#line 649 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 1315 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1338 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 169:
-#line 651 "dhcp6_parser.yy" // lalr1.cc:856
+#line 651 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr pwd(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("password", pwd);
ctx.leave();
}
-#line 1325 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1348 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 170:
-#line 657 "dhcp6_parser.yy" // lalr1.cc:856
+#line 657 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 1333 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1356 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 171:
-#line 659 "dhcp6_parser.yy" // lalr1.cc:856
+#line 659 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr h(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("host", h);
ctx.leave();
}
-#line 1343 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1366 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 172:
-#line 665 "dhcp6_parser.yy" // lalr1.cc:856
+#line 665 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr p(new IntElement(yystack_[0].value.as< int64_t > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("port", p);
}
-#line 1352 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1375 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 173:
-#line 670 "dhcp6_parser.yy" // lalr1.cc:856
+#line 670 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 1360 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1383 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 174:
-#line 672 "dhcp6_parser.yy" // lalr1.cc:856
+#line 672 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr name(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("name", name);
ctx.leave();
}
-#line 1370 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1393 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 175:
-#line 678 "dhcp6_parser.yy" // lalr1.cc:856
+#line 678 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr n(new BoolElement(yystack_[0].value.as< bool > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("persist", n);
}
-#line 1379 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1402 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 176:
-#line 683 "dhcp6_parser.yy" // lalr1.cc:856
+#line 683 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr n(new IntElement(yystack_[0].value.as< int64_t > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("lfc-interval", n);
}
-#line 1388 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1411 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 177:
-#line 688 "dhcp6_parser.yy" // lalr1.cc:856
+#line 688 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr n(new BoolElement(yystack_[0].value.as< bool > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("readonly", n);
}
-#line 1397 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1420 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 178:
-#line 693 "dhcp6_parser.yy" // lalr1.cc:856
+#line 693 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr n(new IntElement(yystack_[0].value.as< int64_t > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("connect-timeout", n);
}
-#line 1406 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1429 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 179:
-#line 698 "dhcp6_parser.yy" // lalr1.cc:856
+#line 698 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr n(new IntElement(yystack_[0].value.as< int64_t > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("reconnect-wait-time", n);
}
-#line 1415 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1438 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 180:
-#line 703 "dhcp6_parser.yy" // lalr1.cc:856
+#line 703 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr n(new IntElement(yystack_[0].value.as< int64_t > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("request-timeout", n);
}
-#line 1424 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1447 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 181:
-#line 708 "dhcp6_parser.yy" // lalr1.cc:856
+#line 708 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr n(new IntElement(yystack_[0].value.as< int64_t > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("tcp-keepalive", n);
}
-#line 1433 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1456 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 182:
-#line 713 "dhcp6_parser.yy" // lalr1.cc:856
+#line 713 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr n(new BoolElement(yystack_[0].value.as< bool > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("tcp-nodelay", n);
}
-#line 1442 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1465 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 183:
-#line 718 "dhcp6_parser.yy" // lalr1.cc:856
+#line 718 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 1450 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1473 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 184:
-#line 720 "dhcp6_parser.yy" // lalr1.cc:856
+#line 720 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr cp(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("contact-points", cp);
ctx.leave();
}
-#line 1460 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1483 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 185:
-#line 726 "dhcp6_parser.yy" // lalr1.cc:856
+#line 726 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr n(new IntElement(yystack_[0].value.as< int64_t > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("max-reconnect-tries", n);
}
-#line 1469 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1492 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 186:
-#line 731 "dhcp6_parser.yy" // lalr1.cc:856
+#line 731 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 1477 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1500 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 187:
-#line 733 "dhcp6_parser.yy" // lalr1.cc:856
+#line 733 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr ks(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("keyspace", ks);
ctx.leave();
}
-#line 1487 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1510 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 188:
-#line 739 "dhcp6_parser.yy" // lalr1.cc:856
+#line 739 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("sanity-checks", m);
ctx.stack_.push_back(m);
ctx.enter(ctx.SANITY_CHECKS);
}
-#line 1498 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1521 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 189:
-#line 744 "dhcp6_parser.yy" // lalr1.cc:856
+#line 744 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
ctx.leave();
}
-#line 1507 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1530 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 193:
-#line 754 "dhcp6_parser.yy" // lalr1.cc:856
+#line 754 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 1515 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1538 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 194:
-#line 756 "dhcp6_parser.yy" // lalr1.cc:856
+#line 756 "dhcp6_parser.yy" // lalr1.cc:907
{
if ( (string(yystack_[0].value.as< std::string > ()) == "none") ||
", supported values are: none, warn, fix, fix-del, del");
}
}
-#line 1535 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1558 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 195:
-#line 772 "dhcp6_parser.yy" // lalr1.cc:856
+#line 772 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr l(new ListElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("mac-sources", l);
ctx.stack_.push_back(l);
ctx.enter(ctx.MAC_SOURCES);
}
-#line 1546 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1569 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 196:
-#line 777 "dhcp6_parser.yy" // lalr1.cc:856
+#line 777 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
ctx.leave();
}
-#line 1555 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1578 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 201:
-#line 790 "dhcp6_parser.yy" // lalr1.cc:856
+#line 790 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr duid(new StringElement("duid", ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->add(duid);
}
-#line 1564 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1587 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 202:
-#line 795 "dhcp6_parser.yy" // lalr1.cc:856
+#line 795 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr duid(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->add(duid);
}
-#line 1573 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1596 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 203:
-#line 800 "dhcp6_parser.yy" // lalr1.cc:856
+#line 800 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr l(new ListElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("host-reservation-identifiers", l);
ctx.stack_.push_back(l);
ctx.enter(ctx.HOST_RESERVATION_IDENTIFIERS);
}
-#line 1584 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1607 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 204:
-#line 805 "dhcp6_parser.yy" // lalr1.cc:856
+#line 805 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
ctx.leave();
}
-#line 1593 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1616 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 210:
-#line 819 "dhcp6_parser.yy" // lalr1.cc:856
+#line 819 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr hwaddr(new StringElement("hw-address", ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->add(hwaddr);
}
-#line 1602 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1625 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 211:
-#line 824 "dhcp6_parser.yy" // lalr1.cc:856
+#line 824 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr flex_id(new StringElement("flex-id", ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->add(flex_id);
}
-#line 1611 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1634 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 212:
-#line 831 "dhcp6_parser.yy" // lalr1.cc:856
+#line 831 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr l(new ListElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("relay-supplied-options", l);
ctx.stack_.push_back(l);
ctx.enter(ctx.NO_KEYWORD);
}
-#line 1622 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1645 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 213:
-#line 836 "dhcp6_parser.yy" // lalr1.cc:856
+#line 836 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
ctx.leave();
}
-#line 1631 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1654 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 214:
-#line 841 "dhcp6_parser.yy" // lalr1.cc:856
+#line 841 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr l(new ListElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("hooks-libraries", l);
ctx.stack_.push_back(l);
ctx.enter(ctx.HOOKS_LIBRARIES);
}
-#line 1642 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1665 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 215:
-#line 846 "dhcp6_parser.yy" // lalr1.cc:856
+#line 846 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
ctx.leave();
}
-#line 1651 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1674 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 220:
-#line 859 "dhcp6_parser.yy" // lalr1.cc:856
+#line 859 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->add(m);
ctx.stack_.push_back(m);
}
-#line 1661 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1684 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 221:
-#line 863 "dhcp6_parser.yy" // lalr1.cc:856
+#line 863 "dhcp6_parser.yy" // lalr1.cc:907
{
// The library hooks parameter is required
ctx.require("library", ctx.loc2pos(yystack_[3].location), ctx.loc2pos(yystack_[0].location));
ctx.stack_.pop_back();
}
-#line 1671 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1694 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 222:
-#line 869 "dhcp6_parser.yy" // lalr1.cc:856
+#line 869 "dhcp6_parser.yy" // lalr1.cc:907
{
// Parse the hooks-libraries list entry map
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.push_back(m);
}
-#line 1681 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1704 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 223:
-#line 873 "dhcp6_parser.yy" // lalr1.cc:856
+#line 873 "dhcp6_parser.yy" // lalr1.cc:907
{
// The library hooks parameter is required
ctx.require("library", ctx.loc2pos(yystack_[3].location), ctx.loc2pos(yystack_[0].location));
// parsing completed
}
-#line 1691 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1714 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 229:
-#line 888 "dhcp6_parser.yy" // lalr1.cc:856
+#line 888 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 1699 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1722 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 230:
-#line 890 "dhcp6_parser.yy" // lalr1.cc:856
+#line 890 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr lib(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("library", lib);
ctx.leave();
}
-#line 1709 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1732 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 231:
-#line 896 "dhcp6_parser.yy" // lalr1.cc:856
+#line 896 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 1717 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1740 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 232:
-#line 898 "dhcp6_parser.yy" // lalr1.cc:856
+#line 898 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.stack_.back()->set("parameters", yystack_[0].value.as< ElementPtr > ());
ctx.leave();
}
-#line 1726 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1749 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 233:
-#line 904 "dhcp6_parser.yy" // lalr1.cc:856
+#line 904 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("expired-leases-processing", m);
ctx.stack_.push_back(m);
ctx.enter(ctx.EXPIRED_LEASES_PROCESSING);
}
-#line 1737 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1760 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 234:
-#line 909 "dhcp6_parser.yy" // lalr1.cc:856
+#line 909 "dhcp6_parser.yy" // lalr1.cc:907
{
// No expired lease parameter is required
ctx.stack_.pop_back();
ctx.leave();
}
-#line 1747 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1770 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 243:
-#line 927 "dhcp6_parser.yy" // lalr1.cc:856
+#line 927 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr value(new IntElement(yystack_[0].value.as< int64_t > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("reclaim-timer-wait-time", value);
}
-#line 1756 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1779 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 244:
-#line 932 "dhcp6_parser.yy" // lalr1.cc:856
+#line 932 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr value(new IntElement(yystack_[0].value.as< int64_t > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("flush-reclaimed-timer-wait-time", value);
}
-#line 1765 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1788 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 245:
-#line 937 "dhcp6_parser.yy" // lalr1.cc:856
+#line 937 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr value(new IntElement(yystack_[0].value.as< int64_t > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("hold-reclaimed-time", value);
}
-#line 1774 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1797 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 246:
-#line 942 "dhcp6_parser.yy" // lalr1.cc:856
+#line 942 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr value(new IntElement(yystack_[0].value.as< int64_t > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("max-reclaim-leases", value);
}
-#line 1783 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1806 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 247:
-#line 947 "dhcp6_parser.yy" // lalr1.cc:856
+#line 947 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr value(new IntElement(yystack_[0].value.as< int64_t > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("max-reclaim-time", value);
}
-#line 1792 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1815 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 248:
-#line 952 "dhcp6_parser.yy" // lalr1.cc:856
+#line 952 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr value(new IntElement(yystack_[0].value.as< int64_t > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("unwarned-reclaim-cycles", value);
}
-#line 1801 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1824 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 249:
-#line 960 "dhcp6_parser.yy" // lalr1.cc:856
+#line 960 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr l(new ListElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("subnet6", l);
ctx.stack_.push_back(l);
ctx.enter(ctx.SUBNET6);
}
-#line 1812 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1835 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 250:
-#line 965 "dhcp6_parser.yy" // lalr1.cc:856
+#line 965 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
ctx.leave();
}
-#line 1821 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1844 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 255:
-#line 985 "dhcp6_parser.yy" // lalr1.cc:856
+#line 985 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->add(m);
ctx.stack_.push_back(m);
}
-#line 1831 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1854 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 256:
-#line 989 "dhcp6_parser.yy" // lalr1.cc:856
+#line 989 "dhcp6_parser.yy" // lalr1.cc:907
{
// Once we reached this place, the subnet parsing is now complete.
// If we want to, we can implement default values here.
ctx.require("subnet", ctx.loc2pos(yystack_[3].location), ctx.loc2pos(yystack_[0].location));
ctx.stack_.pop_back();
}
-#line 1857 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1880 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 257:
-#line 1011 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1011 "dhcp6_parser.yy" // lalr1.cc:907
{
// Parse the subnet6 list entry map
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.push_back(m);
}
-#line 1867 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1890 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 258:
-#line 1015 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1015 "dhcp6_parser.yy" // lalr1.cc:907
{
// The subnet subnet6 parameter is required
ctx.require("subnet", ctx.loc2pos(yystack_[3].location), ctx.loc2pos(yystack_[0].location));
// parsing completed
}
-#line 1877 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1900 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 281:
-#line 1049 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1049 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 1885 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1908 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 282:
-#line 1051 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1051 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr subnet(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("subnet", subnet);
ctx.leave();
}
-#line 1895 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1918 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 283:
-#line 1057 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1057 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 1903 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1926 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 284:
-#line 1059 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1059 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr iface(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("interface", iface);
ctx.leave();
}
-#line 1913 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1936 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 285:
-#line 1065 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1065 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 1921 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1944 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 286:
-#line 1067 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1067 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr iface(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("interface-id", iface);
ctx.leave();
}
-#line 1931 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1954 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 287:
-#line 1073 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1073 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 1939 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1962 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 288:
-#line 1075 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1075 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr cls(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("client-class", cls);
ctx.leave();
}
-#line 1949 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1972 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 289:
-#line 1081 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1081 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr c(new ListElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("require-client-classes", c);
ctx.stack_.push_back(c);
ctx.enter(ctx.NO_KEYWORD);
}
-#line 1960 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1983 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 290:
-#line 1086 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1086 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
ctx.leave();
}
-#line 1969 "dhcp6_parser.cc" // lalr1.cc:856
+#line 1992 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 291:
-#line 1091 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1091 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.RESERVATION_MODE);
}
-#line 1977 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2000 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 292:
-#line 1093 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1093 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.stack_.back()->set("reservation-mode", yystack_[0].value.as< ElementPtr > ());
ctx.leave();
}
-#line 1986 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2009 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 293:
-#line 1098 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1098 "dhcp6_parser.yy" // lalr1.cc:907
{ yylhs.value.as< ElementPtr > () = ElementPtr(new StringElement("disabled", ctx.loc2pos(yystack_[0].location))); }
-#line 1992 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2015 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 294:
-#line 1099 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1099 "dhcp6_parser.yy" // lalr1.cc:907
{ yylhs.value.as< ElementPtr > () = ElementPtr(new StringElement("out-of-pool", ctx.loc2pos(yystack_[0].location))); }
-#line 1998 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2021 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 295:
-#line 1100 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1100 "dhcp6_parser.yy" // lalr1.cc:907
{ yylhs.value.as< ElementPtr > () = ElementPtr(new StringElement("global", ctx.loc2pos(yystack_[0].location))); }
-#line 2004 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2027 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 296:
-#line 1101 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1101 "dhcp6_parser.yy" // lalr1.cc:907
{ yylhs.value.as< ElementPtr > () = ElementPtr(new StringElement("all", ctx.loc2pos(yystack_[0].location))); }
-#line 2010 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2033 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 297:
-#line 1104 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1104 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr id(new IntElement(yystack_[0].value.as< int64_t > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("id", id);
}
-#line 2019 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2042 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 298:
-#line 1109 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1109 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr rc(new BoolElement(yystack_[0].value.as< bool > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("rapid-commit", rc);
}
-#line 2028 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2051 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 299:
-#line 1117 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1117 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr l(new ListElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("shared-networks", l);
ctx.stack_.push_back(l);
ctx.enter(ctx.SHARED_NETWORK);
}
-#line 2039 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2062 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 300:
-#line 1122 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1122 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
ctx.leave();
}
-#line 2048 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2071 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 305:
-#line 1137 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1137 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->add(m);
ctx.stack_.push_back(m);
}
-#line 2058 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2081 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 306:
-#line 1141 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1141 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
}
-#line 2066 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2089 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 326:
-#line 1172 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1172 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr l(new ListElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("option-def", l);
ctx.stack_.push_back(l);
ctx.enter(ctx.OPTION_DEF);
}
-#line 2077 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2100 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 327:
-#line 1177 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1177 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
ctx.leave();
}
-#line 2086 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2109 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 328:
-#line 1185 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1185 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.push_back(m);
}
-#line 2095 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2118 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 329:
-#line 1188 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1188 "dhcp6_parser.yy" // lalr1.cc:907
{
// parsing completed
}
-#line 2103 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2126 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 334:
-#line 1204 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1204 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->add(m);
ctx.stack_.push_back(m);
}
-#line 2113 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2136 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 335:
-#line 1208 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1208 "dhcp6_parser.yy" // lalr1.cc:907
{
// The name, code and type option def parameters are required.
ctx.require("name", ctx.loc2pos(yystack_[3].location), ctx.loc2pos(yystack_[0].location));
ctx.require("type", ctx.loc2pos(yystack_[3].location), ctx.loc2pos(yystack_[0].location));
ctx.stack_.pop_back();
}
-#line 2125 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2148 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 336:
-#line 1219 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1219 "dhcp6_parser.yy" // lalr1.cc:907
{
// Parse the option-def list entry map
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.push_back(m);
}
-#line 2135 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2158 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 337:
-#line 1223 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1223 "dhcp6_parser.yy" // lalr1.cc:907
{
// The name, code and type option def parameters are required.
ctx.require("name", ctx.loc2pos(yystack_[3].location), ctx.loc2pos(yystack_[0].location));
ctx.require("type", ctx.loc2pos(yystack_[3].location), ctx.loc2pos(yystack_[0].location));
// parsing completed
}
-#line 2147 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2170 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 353:
-#line 1255 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1255 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr code(new IntElement(yystack_[0].value.as< int64_t > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("code", code);
}
-#line 2156 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2179 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 355:
-#line 1262 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1262 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 2164 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2187 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 356:
-#line 1264 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1264 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr prf(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("type", prf);
ctx.leave();
}
-#line 2174 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2197 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 357:
-#line 1270 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1270 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 2182 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2205 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 358:
-#line 1272 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1272 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr rtypes(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("record-types", rtypes);
ctx.leave();
}
-#line 2192 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2215 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 359:
-#line 1278 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1278 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 2200 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2223 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 360:
-#line 1280 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1280 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr space(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("space", space);
ctx.leave();
}
-#line 2210 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2233 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 362:
-#line 1288 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1288 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 2218 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2241 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 363:
-#line 1290 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1290 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr encap(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("encapsulate", encap);
ctx.leave();
}
-#line 2228 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2251 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 364:
-#line 1296 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1296 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr array(new BoolElement(yystack_[0].value.as< bool > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("array", array);
}
-#line 2237 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2260 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 365:
-#line 1305 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1305 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr l(new ListElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("option-data", l);
ctx.stack_.push_back(l);
ctx.enter(ctx.OPTION_DATA);
}
-#line 2248 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2271 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 366:
-#line 1310 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1310 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
ctx.leave();
}
-#line 2257 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2280 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 371:
-#line 1329 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1329 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->add(m);
ctx.stack_.push_back(m);
}
-#line 2267 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2290 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 372:
-#line 1333 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1333 "dhcp6_parser.yy" // lalr1.cc:907
{
/// @todo: the code or name parameters are required.
ctx.stack_.pop_back();
}
-#line 2276 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2299 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 373:
-#line 1341 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1341 "dhcp6_parser.yy" // lalr1.cc:907
{
// Parse the option-data list entry map
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.push_back(m);
}
-#line 2286 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2309 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 374:
-#line 1345 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1345 "dhcp6_parser.yy" // lalr1.cc:907
{
/// @todo: the code or name parameters are required.
// parsing completed
}
-#line 2295 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2318 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 389:
-#line 1378 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1378 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 2303 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2326 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 390:
-#line 1380 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1380 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr data(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("data", data);
ctx.leave();
}
-#line 2313 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2336 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 393:
-#line 1390 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1390 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr space(new BoolElement(yystack_[0].value.as< bool > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("csv-format", space);
}
-#line 2322 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2345 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 394:
-#line 1395 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1395 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr persist(new BoolElement(yystack_[0].value.as< bool > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("always-send", persist);
}
-#line 2331 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2354 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 395:
-#line 1403 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1403 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr l(new ListElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("pools", l);
ctx.stack_.push_back(l);
ctx.enter(ctx.POOLS);
}
-#line 2342 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2365 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 396:
-#line 1408 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1408 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
ctx.leave();
}
-#line 2351 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2374 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 401:
-#line 1423 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1423 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->add(m);
ctx.stack_.push_back(m);
}
-#line 2361 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2384 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 402:
-#line 1427 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1427 "dhcp6_parser.yy" // lalr1.cc:907
{
// The pool parameter is required.
ctx.require("pool", ctx.loc2pos(yystack_[3].location), ctx.loc2pos(yystack_[0].location));
ctx.stack_.pop_back();
}
-#line 2371 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2394 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 403:
-#line 1433 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1433 "dhcp6_parser.yy" // lalr1.cc:907
{
// Parse the pool list entry map
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.push_back(m);
}
-#line 2381 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2404 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 404:
-#line 1437 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1437 "dhcp6_parser.yy" // lalr1.cc:907
{
// The pool parameter is required.
ctx.require("pool", ctx.loc2pos(yystack_[3].location), ctx.loc2pos(yystack_[0].location));
}
-#line 2390 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2413 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 414:
-#line 1455 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1455 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 2398 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2421 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 415:
-#line 1457 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1457 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr pool(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("pool", pool);
ctx.leave();
}
-#line 2408 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2431 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 416:
-#line 1463 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1463 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 2416 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2439 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 417:
-#line 1465 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1465 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr parent = ctx.stack_.back();
ElementPtr user_context = yystack_[0].value.as< ElementPtr > ();
parent->set("user-context", user_context);
ctx.leave();
}
-#line 2443 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2466 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 418:
-#line 1488 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1488 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 2451 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2474 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 419:
-#line 1490 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1490 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr parent = ctx.stack_.back();
ElementPtr user_context(new MapElement(ctx.loc2pos(yystack_[3].location)));
parent->set("user-context", user_context);
ctx.leave();
}
-#line 2480 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2503 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 420:
-#line 1518 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1518 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr l(new ListElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("pd-pools", l);
ctx.stack_.push_back(l);
ctx.enter(ctx.PD_POOLS);
}
-#line 2491 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2514 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 421:
-#line 1523 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1523 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
ctx.leave();
}
-#line 2500 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2523 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 426:
-#line 1538 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1538 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->add(m);
ctx.stack_.push_back(m);
}
-#line 2510 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2533 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 427:
-#line 1542 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1542 "dhcp6_parser.yy" // lalr1.cc:907
{
// The prefix, prefix len and delegated len parameters are required.
ctx.require("prefix", ctx.loc2pos(yystack_[3].location), ctx.loc2pos(yystack_[0].location));
ctx.require("delegated-len", ctx.loc2pos(yystack_[3].location), ctx.loc2pos(yystack_[0].location));
ctx.stack_.pop_back();
}
-#line 2522 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2545 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 428:
-#line 1550 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1550 "dhcp6_parser.yy" // lalr1.cc:907
{
// Parse the pd-pool list entry map
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.push_back(m);
}
-#line 2532 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2555 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 429:
-#line 1554 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1554 "dhcp6_parser.yy" // lalr1.cc:907
{
// The prefix, prefix len and delegated len parameters are required.
ctx.require("prefix", ctx.loc2pos(yystack_[3].location), ctx.loc2pos(yystack_[0].location));
ctx.require("delegated-len", ctx.loc2pos(yystack_[3].location), ctx.loc2pos(yystack_[0].location));
// parsing completed
}
-#line 2544 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2567 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 443:
-#line 1579 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1579 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 2552 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2575 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 444:
-#line 1581 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1581 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr prf(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("prefix", prf);
ctx.leave();
}
-#line 2562 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2585 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 445:
-#line 1587 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1587 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr prf(new IntElement(yystack_[0].value.as< int64_t > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("prefix-len", prf);
}
-#line 2571 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2594 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 446:
-#line 1592 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1592 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 2579 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2602 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 447:
-#line 1594 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1594 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr prf(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("excluded-prefix", prf);
ctx.leave();
}
-#line 2589 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2612 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 448:
-#line 1600 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1600 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr prf(new IntElement(yystack_[0].value.as< int64_t > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("excluded-prefix-len", prf);
}
-#line 2598 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2621 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 449:
-#line 1605 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1605 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr deleg(new IntElement(yystack_[0].value.as< int64_t > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("delegated-len", deleg);
}
-#line 2607 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2630 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 450:
-#line 1613 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1613 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr l(new ListElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("reservations", l);
ctx.stack_.push_back(l);
ctx.enter(ctx.RESERVATIONS);
}
-#line 2618 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2641 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 451:
-#line 1618 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1618 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
ctx.leave();
}
-#line 2627 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2650 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 456:
-#line 1631 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1631 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->add(m);
ctx.stack_.push_back(m);
}
-#line 2637 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2660 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 457:
-#line 1635 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1635 "dhcp6_parser.yy" // lalr1.cc:907
{
/// @todo: an identifier parameter is required.
ctx.stack_.pop_back();
}
-#line 2646 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2669 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 458:
-#line 1640 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1640 "dhcp6_parser.yy" // lalr1.cc:907
{
// Parse the reservations list entry map
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.push_back(m);
}
-#line 2656 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2679 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 459:
-#line 1644 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1644 "dhcp6_parser.yy" // lalr1.cc:907
{
/// @todo: an identifier parameter is required.
// parsing completed
}
-#line 2665 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2688 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 475:
-#line 1671 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1671 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr l(new ListElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("ip-addresses", l);
ctx.stack_.push_back(l);
ctx.enter(ctx.NO_KEYWORD);
}
-#line 2676 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2699 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 476:
-#line 1676 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1676 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
ctx.leave();
}
-#line 2685 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2708 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 477:
-#line 1681 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1681 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr l(new ListElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("prefixes", l);
ctx.stack_.push_back(l);
ctx.enter(ctx.NO_KEYWORD);
}
-#line 2696 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2719 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 478:
-#line 1686 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1686 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
ctx.leave();
}
-#line 2705 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2728 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 479:
-#line 1691 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1691 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 2713 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2736 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 480:
-#line 1693 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1693 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr d(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("duid", d);
ctx.leave();
}
-#line 2723 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2746 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 481:
-#line 1699 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1699 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 2731 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2754 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 482:
-#line 1701 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1701 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr hw(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("hw-address", hw);
ctx.leave();
}
-#line 2741 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2764 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 483:
-#line 1707 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1707 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 2749 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2772 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 484:
-#line 1709 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1709 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr host(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("hostname", host);
ctx.leave();
}
-#line 2759 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2782 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 485:
-#line 1715 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1715 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 2767 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2790 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 486:
-#line 1717 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1717 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr hw(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("flex-id", hw);
ctx.leave();
}
-#line 2777 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2800 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 487:
-#line 1723 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1723 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr c(new ListElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("client-classes", c);
ctx.stack_.push_back(c);
ctx.enter(ctx.NO_KEYWORD);
}
-#line 2788 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2811 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 488:
-#line 1728 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1728 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
ctx.leave();
}
-#line 2797 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2820 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 489:
-#line 1736 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1736 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("relay", m);
ctx.stack_.push_back(m);
ctx.enter(ctx.RELAY);
}
-#line 2808 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2831 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 490:
-#line 1741 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1741 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
ctx.leave();
}
-#line 2817 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2840 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 493:
-#line 1750 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1750 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 2825 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2848 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 494:
-#line 1752 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1752 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr addr(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("ip-address", addr);
ctx.leave();
}
-#line 2835 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2858 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 495:
-#line 1761 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1761 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr l(new ListElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("client-classes", l);
ctx.stack_.push_back(l);
ctx.enter(ctx.CLIENT_CLASSES);
}
-#line 2846 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2869 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 496:
-#line 1766 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1766 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
ctx.leave();
}
-#line 2855 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2878 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 499:
-#line 1775 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1775 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->add(m);
ctx.stack_.push_back(m);
}
-#line 2865 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2888 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 500:
-#line 1779 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1779 "dhcp6_parser.yy" // lalr1.cc:907
{
// The name client class parameter is required.
ctx.require("name", ctx.loc2pos(yystack_[3].location), ctx.loc2pos(yystack_[0].location));
ctx.stack_.pop_back();
}
-#line 2875 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2898 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 513:
-#line 1804 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1804 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 2883 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2906 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 514:
-#line 1806 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1806 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr test(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("test", test);
ctx.leave();
}
-#line 2893 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2916 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 515:
-#line 1812 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1812 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr b(new BoolElement(yystack_[0].value.as< bool > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("only-if-required", b);
}
-#line 2902 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2925 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 516:
-#line 1820 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1820 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("server-id", m);
ctx.stack_.push_back(m);
ctx.enter(ctx.SERVER_ID);
}
-#line 2913 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2936 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 517:
-#line 1825 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1825 "dhcp6_parser.yy" // lalr1.cc:907
{
// The type parameter is required.
ctx.require("type", ctx.loc2pos(yystack_[2].location), ctx.loc2pos(yystack_[0].location));
ctx.stack_.pop_back();
ctx.leave();
}
-#line 2924 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2947 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 529:
-#line 1847 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1847 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.DUID_TYPE);
}
-#line 2932 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2955 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 530:
-#line 1849 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1849 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.stack_.back()->set("type", yystack_[0].value.as< ElementPtr > ());
ctx.leave();
}
-#line 2941 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2964 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 531:
-#line 1854 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1854 "dhcp6_parser.yy" // lalr1.cc:907
{ yylhs.value.as< ElementPtr > () = ElementPtr(new StringElement("LLT", ctx.loc2pos(yystack_[0].location))); }
-#line 2947 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2970 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 532:
-#line 1855 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1855 "dhcp6_parser.yy" // lalr1.cc:907
{ yylhs.value.as< ElementPtr > () = ElementPtr(new StringElement("EN", ctx.loc2pos(yystack_[0].location))); }
-#line 2953 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2976 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 533:
-#line 1856 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1856 "dhcp6_parser.yy" // lalr1.cc:907
{ yylhs.value.as< ElementPtr > () = ElementPtr(new StringElement("LL", ctx.loc2pos(yystack_[0].location))); }
-#line 2959 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2982 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 534:
-#line 1859 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1859 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr htype(new IntElement(yystack_[0].value.as< int64_t > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("htype", htype);
}
-#line 2968 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2991 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 535:
-#line 1864 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1864 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 2976 "dhcp6_parser.cc" // lalr1.cc:856
+#line 2999 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 536:
-#line 1866 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1866 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr id(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("identifier", id);
ctx.leave();
}
-#line 2986 "dhcp6_parser.cc" // lalr1.cc:856
+#line 3009 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 537:
-#line 1872 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1872 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr time(new IntElement(yystack_[0].value.as< int64_t > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("time", time);
}
-#line 2995 "dhcp6_parser.cc" // lalr1.cc:856
+#line 3018 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 538:
-#line 1877 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1877 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr time(new IntElement(yystack_[0].value.as< int64_t > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("enterprise-id", time);
}
-#line 3004 "dhcp6_parser.cc" // lalr1.cc:856
+#line 3027 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 539:
-#line 1884 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1884 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr time(new IntElement(yystack_[0].value.as< int64_t > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("dhcp4o6-port", time);
}
-#line 3013 "dhcp6_parser.cc" // lalr1.cc:856
+#line 3036 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 540:
-#line 1891 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1891 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("control-socket", m);
ctx.stack_.push_back(m);
ctx.enter(ctx.CONTROL_SOCKET);
}
-#line 3024 "dhcp6_parser.cc" // lalr1.cc:856
+#line 3047 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 541:
-#line 1896 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1896 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
ctx.leave();
}
-#line 3033 "dhcp6_parser.cc" // lalr1.cc:856
+#line 3056 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 549:
-#line 1912 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1912 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 3041 "dhcp6_parser.cc" // lalr1.cc:856
+#line 3064 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 550:
-#line 1914 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1914 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr stype(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("socket-type", stype);
ctx.leave();
}
-#line 3051 "dhcp6_parser.cc" // lalr1.cc:856
+#line 3074 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 551:
-#line 1920 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1920 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 3059 "dhcp6_parser.cc" // lalr1.cc:856
+#line 3082 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 552:
-#line 1922 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1922 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr name(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("socket-name", name);
ctx.leave();
}
-#line 3069 "dhcp6_parser.cc" // lalr1.cc:856
+#line 3092 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 553:
-#line 1930 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1930 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 3077 "dhcp6_parser.cc" // lalr1.cc:856
+#line 3100 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 554:
-#line 1932 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1932 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr qc = yystack_[0].value.as< ElementPtr > ();
ctx.stack_.back()->set("dhcp-queue-control", qc);
ctx.leave();
}
-#line 3095 "dhcp6_parser.cc" // lalr1.cc:856
+#line 3118 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 555:
-#line 1948 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1948 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("dhcp-ddns", m);
ctx.stack_.push_back(m);
ctx.enter(ctx.DHCP_DDNS);
}
-#line 3106 "dhcp6_parser.cc" // lalr1.cc:856
+#line 3129 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 556:
-#line 1953 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1953 "dhcp6_parser.yy" // lalr1.cc:907
{
// The enable updates DHCP DDNS parameter is required.
ctx.require("enable-updates", ctx.loc2pos(yystack_[2].location), ctx.loc2pos(yystack_[0].location));
ctx.stack_.pop_back();
ctx.leave();
}
-#line 3117 "dhcp6_parser.cc" // lalr1.cc:856
+#line 3140 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 557:
-#line 1960 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1960 "dhcp6_parser.yy" // lalr1.cc:907
{
// Parse the dhcp-ddns map
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.push_back(m);
}
-#line 3127 "dhcp6_parser.cc" // lalr1.cc:856
+#line 3150 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 558:
-#line 1964 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1964 "dhcp6_parser.yy" // lalr1.cc:907
{
// The enable updates DHCP DDNS parameter is required.
ctx.require("enable-updates", ctx.loc2pos(yystack_[3].location), ctx.loc2pos(yystack_[0].location));
// parsing completed
}
-#line 3137 "dhcp6_parser.cc" // lalr1.cc:856
+#line 3160 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 580:
-#line 1995 "dhcp6_parser.yy" // lalr1.cc:856
+#line 1995 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr b(new BoolElement(yystack_[0].value.as< bool > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("enable-updates", b);
}
-#line 3146 "dhcp6_parser.cc" // lalr1.cc:856
+#line 3169 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 581:
-#line 2000 "dhcp6_parser.yy" // lalr1.cc:856
+#line 2000 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 3154 "dhcp6_parser.cc" // lalr1.cc:856
+#line 3177 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 582:
-#line 2002 "dhcp6_parser.yy" // lalr1.cc:856
+#line 2002 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr s(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("qualifying-suffix", s);
ctx.leave();
}
-#line 3164 "dhcp6_parser.cc" // lalr1.cc:856
+#line 3187 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 583:
-#line 2008 "dhcp6_parser.yy" // lalr1.cc:856
+#line 2008 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 3172 "dhcp6_parser.cc" // lalr1.cc:856
+#line 3195 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 584:
-#line 2010 "dhcp6_parser.yy" // lalr1.cc:856
+#line 2010 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr s(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("server-ip", s);
ctx.leave();
}
-#line 3182 "dhcp6_parser.cc" // lalr1.cc:856
+#line 3205 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 585:
-#line 2016 "dhcp6_parser.yy" // lalr1.cc:856
+#line 2016 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr i(new IntElement(yystack_[0].value.as< int64_t > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("server-port", i);
}
-#line 3191 "dhcp6_parser.cc" // lalr1.cc:856
+#line 3214 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 586:
-#line 2021 "dhcp6_parser.yy" // lalr1.cc:856
+#line 2021 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 3199 "dhcp6_parser.cc" // lalr1.cc:856
+#line 3222 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 587:
-#line 2023 "dhcp6_parser.yy" // lalr1.cc:856
+#line 2023 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr s(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("sender-ip", s);
ctx.leave();
}
-#line 3209 "dhcp6_parser.cc" // lalr1.cc:856
+#line 3232 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 588:
-#line 2029 "dhcp6_parser.yy" // lalr1.cc:856
+#line 2029 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr i(new IntElement(yystack_[0].value.as< int64_t > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("sender-port", i);
}
-#line 3218 "dhcp6_parser.cc" // lalr1.cc:856
+#line 3241 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 589:
-#line 2034 "dhcp6_parser.yy" // lalr1.cc:856
+#line 2034 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr i(new IntElement(yystack_[0].value.as< int64_t > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("max-queue-size", i);
}
-#line 3227 "dhcp6_parser.cc" // lalr1.cc:856
+#line 3250 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 590:
-#line 2039 "dhcp6_parser.yy" // lalr1.cc:856
+#line 2039 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NCR_PROTOCOL);
}
-#line 3235 "dhcp6_parser.cc" // lalr1.cc:856
+#line 3258 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 591:
-#line 2041 "dhcp6_parser.yy" // lalr1.cc:856
+#line 2041 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.stack_.back()->set("ncr-protocol", yystack_[0].value.as< ElementPtr > ());
ctx.leave();
}
-#line 3244 "dhcp6_parser.cc" // lalr1.cc:856
+#line 3267 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 592:
-#line 2047 "dhcp6_parser.yy" // lalr1.cc:856
+#line 2047 "dhcp6_parser.yy" // lalr1.cc:907
{ yylhs.value.as< ElementPtr > () = ElementPtr(new StringElement("UDP", ctx.loc2pos(yystack_[0].location))); }
-#line 3250 "dhcp6_parser.cc" // lalr1.cc:856
+#line 3273 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 593:
-#line 2048 "dhcp6_parser.yy" // lalr1.cc:856
+#line 2048 "dhcp6_parser.yy" // lalr1.cc:907
{ yylhs.value.as< ElementPtr > () = ElementPtr(new StringElement("TCP", ctx.loc2pos(yystack_[0].location))); }
-#line 3256 "dhcp6_parser.cc" // lalr1.cc:856
+#line 3279 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 594:
-#line 2051 "dhcp6_parser.yy" // lalr1.cc:856
+#line 2051 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NCR_FORMAT);
}
-#line 3264 "dhcp6_parser.cc" // lalr1.cc:856
+#line 3287 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 595:
-#line 2053 "dhcp6_parser.yy" // lalr1.cc:856
+#line 2053 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr json(new StringElement("JSON", ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("ncr-format", json);
ctx.leave();
}
-#line 3274 "dhcp6_parser.cc" // lalr1.cc:856
+#line 3297 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 596:
-#line 2059 "dhcp6_parser.yy" // lalr1.cc:856
+#line 2059 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr b(new BoolElement(yystack_[0].value.as< bool > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("always-include-fqdn", b);
}
-#line 3283 "dhcp6_parser.cc" // lalr1.cc:856
+#line 3306 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 597:
-#line 2064 "dhcp6_parser.yy" // lalr1.cc:856
+#line 2064 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr b(new BoolElement(yystack_[0].value.as< bool > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("override-no-update", b);
}
-#line 3292 "dhcp6_parser.cc" // lalr1.cc:856
+#line 3315 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 598:
-#line 2069 "dhcp6_parser.yy" // lalr1.cc:856
+#line 2069 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr b(new BoolElement(yystack_[0].value.as< bool > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("override-client-update", b);
}
-#line 3301 "dhcp6_parser.cc" // lalr1.cc:856
+#line 3324 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 599:
-#line 2074 "dhcp6_parser.yy" // lalr1.cc:856
+#line 2074 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.REPLACE_CLIENT_NAME);
}
-#line 3309 "dhcp6_parser.cc" // lalr1.cc:856
+#line 3332 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 600:
-#line 2076 "dhcp6_parser.yy" // lalr1.cc:856
+#line 2076 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.stack_.back()->set("replace-client-name", yystack_[0].value.as< ElementPtr > ());
ctx.leave();
}
-#line 3318 "dhcp6_parser.cc" // lalr1.cc:856
+#line 3341 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 601:
-#line 2082 "dhcp6_parser.yy" // lalr1.cc:856
+#line 2082 "dhcp6_parser.yy" // lalr1.cc:907
{
yylhs.value.as< ElementPtr > () = ElementPtr(new StringElement("when-present", ctx.loc2pos(yystack_[0].location)));
}
-#line 3326 "dhcp6_parser.cc" // lalr1.cc:856
+#line 3349 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 602:
-#line 2085 "dhcp6_parser.yy" // lalr1.cc:856
+#line 2085 "dhcp6_parser.yy" // lalr1.cc:907
{
yylhs.value.as< ElementPtr > () = ElementPtr(new StringElement("never", ctx.loc2pos(yystack_[0].location)));
}
-#line 3334 "dhcp6_parser.cc" // lalr1.cc:856
+#line 3357 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 603:
-#line 2088 "dhcp6_parser.yy" // lalr1.cc:856
+#line 2088 "dhcp6_parser.yy" // lalr1.cc:907
{
yylhs.value.as< ElementPtr > () = ElementPtr(new StringElement("always", ctx.loc2pos(yystack_[0].location)));
}
-#line 3342 "dhcp6_parser.cc" // lalr1.cc:856
+#line 3365 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 604:
-#line 2091 "dhcp6_parser.yy" // lalr1.cc:856
+#line 2091 "dhcp6_parser.yy" // lalr1.cc:907
{
yylhs.value.as< ElementPtr > () = ElementPtr(new StringElement("when-not-present", ctx.loc2pos(yystack_[0].location)));
}
-#line 3350 "dhcp6_parser.cc" // lalr1.cc:856
+#line 3373 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 605:
-#line 2094 "dhcp6_parser.yy" // lalr1.cc:856
+#line 2094 "dhcp6_parser.yy" // lalr1.cc:907
{
error(yystack_[0].location, "boolean values for the replace-client-name are "
"no longer supported");
}
-#line 3359 "dhcp6_parser.cc" // lalr1.cc:856
+#line 3382 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 606:
-#line 2100 "dhcp6_parser.yy" // lalr1.cc:856
+#line 2100 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 3367 "dhcp6_parser.cc" // lalr1.cc:856
+#line 3390 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 607:
-#line 2102 "dhcp6_parser.yy" // lalr1.cc:856
+#line 2102 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr s(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("generated-prefix", s);
ctx.leave();
}
-#line 3377 "dhcp6_parser.cc" // lalr1.cc:856
+#line 3400 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 608:
-#line 2108 "dhcp6_parser.yy" // lalr1.cc:856
+#line 2108 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 3385 "dhcp6_parser.cc" // lalr1.cc:856
+#line 3408 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 609:
-#line 2110 "dhcp6_parser.yy" // lalr1.cc:856
+#line 2110 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr s(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("hostname-char-set", s);
ctx.leave();
}
-#line 3395 "dhcp6_parser.cc" // lalr1.cc:856
+#line 3418 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 610:
-#line 2116 "dhcp6_parser.yy" // lalr1.cc:856
+#line 2116 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 3403 "dhcp6_parser.cc" // lalr1.cc:856
+#line 3426 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 611:
-#line 2118 "dhcp6_parser.yy" // lalr1.cc:856
+#line 2118 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr s(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("hostname-char-replacement", s);
ctx.leave();
}
-#line 3413 "dhcp6_parser.cc" // lalr1.cc:856
+#line 3436 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 612:
-#line 2126 "dhcp6_parser.yy" // lalr1.cc:856
+#line 2126 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 3421 "dhcp6_parser.cc" // lalr1.cc:856
+#line 3444 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 613:
-#line 2128 "dhcp6_parser.yy" // lalr1.cc:856
+#line 2128 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.stack_.back()->set("Dhcp4", yystack_[0].value.as< ElementPtr > ());
ctx.leave();
}
-#line 3430 "dhcp6_parser.cc" // lalr1.cc:856
+#line 3453 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 614:
-#line 2133 "dhcp6_parser.yy" // lalr1.cc:856
+#line 2133 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 3438 "dhcp6_parser.cc" // lalr1.cc:856
+#line 3461 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 615:
-#line 2135 "dhcp6_parser.yy" // lalr1.cc:856
+#line 2135 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.stack_.back()->set("DhcpDdns", yystack_[0].value.as< ElementPtr > ());
ctx.leave();
}
-#line 3447 "dhcp6_parser.cc" // lalr1.cc:856
+#line 3470 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 616:
-#line 2140 "dhcp6_parser.yy" // lalr1.cc:856
+#line 2140 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 3455 "dhcp6_parser.cc" // lalr1.cc:856
+#line 3478 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 617:
-#line 2142 "dhcp6_parser.yy" // lalr1.cc:856
+#line 2142 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.stack_.back()->set("Control-agent", yystack_[0].value.as< ElementPtr > ());
ctx.leave();
}
-#line 3464 "dhcp6_parser.cc" // lalr1.cc:856
+#line 3487 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 618:
-#line 2149 "dhcp6_parser.yy" // lalr1.cc:856
+#line 2149 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->add(m);
ctx.stack_.push_back(m);
}
-#line 3474 "dhcp6_parser.cc" // lalr1.cc:856
+#line 3497 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 619:
-#line 2153 "dhcp6_parser.yy" // lalr1.cc:856
+#line 2153 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
}
-#line 3482 "dhcp6_parser.cc" // lalr1.cc:856
+#line 3505 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 620:
-#line 2158 "dhcp6_parser.yy" // lalr1.cc:856
+#line 2158 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr i(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("config-control", i);
ctx.stack_.push_back(i);
ctx.enter(ctx.CONFIG_CONTROL);
}
-#line 3493 "dhcp6_parser.cc" // lalr1.cc:856
+#line 3516 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 621:
-#line 2163 "dhcp6_parser.yy" // lalr1.cc:856
+#line 2163 "dhcp6_parser.yy" // lalr1.cc:907
{
// No config control params are required
ctx.stack_.pop_back();
ctx.leave();
}
-#line 3503 "dhcp6_parser.cc" // lalr1.cc:856
+#line 3526 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 622:
-#line 2169 "dhcp6_parser.yy" // lalr1.cc:856
+#line 2169 "dhcp6_parser.yy" // lalr1.cc:907
{
// Parse the config-control map
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.push_back(m);
}
-#line 3513 "dhcp6_parser.cc" // lalr1.cc:856
+#line 3536 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 623:
-#line 2173 "dhcp6_parser.yy" // lalr1.cc:856
+#line 2173 "dhcp6_parser.yy" // lalr1.cc:907
{
// No config_control params are required
// parsing completed
}
-#line 3522 "dhcp6_parser.cc" // lalr1.cc:856
+#line 3545 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 628:
-#line 2188 "dhcp6_parser.yy" // lalr1.cc:856
+#line 2188 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr l(new ListElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("config-databases", l);
ctx.stack_.push_back(l);
ctx.enter(ctx.CONFIG_DATABASE);
}
-#line 3533 "dhcp6_parser.cc" // lalr1.cc:856
+#line 3556 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 629:
-#line 2193 "dhcp6_parser.yy" // lalr1.cc:856
+#line 2193 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
ctx.leave();
}
-#line 3542 "dhcp6_parser.cc" // lalr1.cc:856
+#line 3565 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 630:
-#line 2203 "dhcp6_parser.yy" // lalr1.cc:856
+#line 2203 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("Logging", m);
ctx.stack_.push_back(m);
ctx.enter(ctx.LOGGING);
}
-#line 3553 "dhcp6_parser.cc" // lalr1.cc:856
+#line 3576 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 631:
-#line 2208 "dhcp6_parser.yy" // lalr1.cc:856
+#line 2208 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
ctx.leave();
}
-#line 3562 "dhcp6_parser.cc" // lalr1.cc:856
+#line 3585 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 632:
-#line 2213 "dhcp6_parser.yy" // lalr1.cc:856
+#line 2213 "dhcp6_parser.yy" // lalr1.cc:907
{
// Parse the Logging map
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.push_back(m);
}
-#line 3572 "dhcp6_parser.cc" // lalr1.cc:856
+#line 3595 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 633:
-#line 2217 "dhcp6_parser.yy" // lalr1.cc:856
+#line 2217 "dhcp6_parser.yy" // lalr1.cc:907
{
// parsing completed
}
-#line 3580 "dhcp6_parser.cc" // lalr1.cc:856
+#line 3603 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 637:
-#line 2233 "dhcp6_parser.yy" // lalr1.cc:856
+#line 2233 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr l(new ListElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("loggers", l);
ctx.stack_.push_back(l);
ctx.enter(ctx.LOGGERS);
}
-#line 3591 "dhcp6_parser.cc" // lalr1.cc:856
+#line 3614 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 638:
-#line 2238 "dhcp6_parser.yy" // lalr1.cc:856
+#line 2238 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
ctx.leave();
}
-#line 3600 "dhcp6_parser.cc" // lalr1.cc:856
+#line 3623 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 641:
-#line 2250 "dhcp6_parser.yy" // lalr1.cc:856
+#line 2250 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr l(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->add(l);
ctx.stack_.push_back(l);
}
-#line 3610 "dhcp6_parser.cc" // lalr1.cc:856
+#line 3633 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 642:
-#line 2254 "dhcp6_parser.yy" // lalr1.cc:856
+#line 2254 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
}
-#line 3618 "dhcp6_parser.cc" // lalr1.cc:856
+#line 3641 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 652:
-#line 2271 "dhcp6_parser.yy" // lalr1.cc:856
+#line 2271 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr dl(new IntElement(yystack_[0].value.as< int64_t > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("debuglevel", dl);
}
-#line 3627 "dhcp6_parser.cc" // lalr1.cc:856
+#line 3650 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 653:
-#line 2276 "dhcp6_parser.yy" // lalr1.cc:856
+#line 2276 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 3635 "dhcp6_parser.cc" // lalr1.cc:856
+#line 3658 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 654:
-#line 2278 "dhcp6_parser.yy" // lalr1.cc:856
+#line 2278 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr sev(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("severity", sev);
ctx.leave();
}
-#line 3645 "dhcp6_parser.cc" // lalr1.cc:856
+#line 3668 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 655:
-#line 2284 "dhcp6_parser.yy" // lalr1.cc:856
+#line 2284 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr l(new ListElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("output_options", l);
ctx.stack_.push_back(l);
ctx.enter(ctx.OUTPUT_OPTIONS);
}
-#line 3656 "dhcp6_parser.cc" // lalr1.cc:856
+#line 3679 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 656:
-#line 2289 "dhcp6_parser.yy" // lalr1.cc:856
+#line 2289 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
ctx.leave();
}
-#line 3665 "dhcp6_parser.cc" // lalr1.cc:856
+#line 3688 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 659:
-#line 2298 "dhcp6_parser.yy" // lalr1.cc:856
+#line 2298 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->add(m);
ctx.stack_.push_back(m);
}
-#line 3675 "dhcp6_parser.cc" // lalr1.cc:856
+#line 3698 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 660:
-#line 2302 "dhcp6_parser.yy" // lalr1.cc:856
+#line 2302 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
}
-#line 3683 "dhcp6_parser.cc" // lalr1.cc:856
+#line 3706 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 667:
-#line 2316 "dhcp6_parser.yy" // lalr1.cc:856
+#line 2316 "dhcp6_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORD);
}
-#line 3691 "dhcp6_parser.cc" // lalr1.cc:856
+#line 3714 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 668:
-#line 2318 "dhcp6_parser.yy" // lalr1.cc:856
+#line 2318 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr sev(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("output", sev);
ctx.leave();
}
-#line 3701 "dhcp6_parser.cc" // lalr1.cc:856
+#line 3724 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 669:
-#line 2324 "dhcp6_parser.yy" // lalr1.cc:856
+#line 2324 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr flush(new BoolElement(yystack_[0].value.as< bool > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("flush", flush);
}
-#line 3710 "dhcp6_parser.cc" // lalr1.cc:856
+#line 3733 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 670:
-#line 2329 "dhcp6_parser.yy" // lalr1.cc:856
+#line 2329 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr maxsize(new IntElement(yystack_[0].value.as< int64_t > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("maxsize", maxsize);
}
-#line 3719 "dhcp6_parser.cc" // lalr1.cc:856
+#line 3742 "dhcp6_parser.cc" // lalr1.cc:907
break;
case 671:
-#line 2334 "dhcp6_parser.yy" // lalr1.cc:856
+#line 2334 "dhcp6_parser.yy" // lalr1.cc:907
{
ElementPtr maxver(new IntElement(yystack_[0].value.as< int64_t > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("maxver", maxver);
}
-#line 3728 "dhcp6_parser.cc" // lalr1.cc:856
+#line 3751 "dhcp6_parser.cc" // lalr1.cc:907
break;
-#line 3732 "dhcp6_parser.cc" // lalr1.cc:856
+#line 3755 "dhcp6_parser.cc" // lalr1.cc:907
default:
break;
}
}
+#if YY_EXCEPTIONS
catch (const syntax_error& yyexc)
{
error (yyexc);
YYERROR;
}
+#endif // YY_EXCEPTIONS
YY_SYMBOL_PRINT ("-> $$ =", yylhs);
yypop_ (yylen);
yylen = 0;
YY_STACK_PRINT ();
// Shift the result of the reduction.
- yypush_ (YY_NULLPTR, yylhs);
+ yypush_ (YY_NULLPTR, YY_MOVE (yylhs));
}
goto yynewstate;
// Shift the error token.
error_token.state = yyn;
- yypush_ ("Shifting", error_token);
+ yypush_ ("Shifting", YY_MOVE (error_token));
}
goto yynewstate;
return yyresult;
}
+#if YY_EXCEPTIONS
catch (...)
{
YYCDEBUG << "Exception caught: cleaning lookahead and stack\n";
// Do not try to display the values of the reclaimed symbols,
- // as their printer might throw an exception.
+ // as their printers might throw an exception.
if (!yyla.empty ())
yy_destroy_ (YY_NULLPTR, yyla);
}
throw;
}
+#endif // YY_EXCEPTIONS
}
void
}
- const short int Dhcp6Parser::yypact_ninf_ = -824;
+ const short Dhcp6Parser::yypact_ninf_ = -824;
const signed char Dhcp6Parser::yytable_ninf_ = -1;
- const short int
+ const short
Dhcp6Parser::yypact_[] =
{
321, -824, -824, -824, -824, -824, -824, -824, -824, -824,
-824, -824, -824, -824
};
- const unsigned short int
+ const unsigned short
Dhcp6Parser::yydefact_[] =
{
0, 2, 4, 6, 8, 10, 12, 14, 16, 18,
670, 671, 662, 668
};
- const short int
+ const short
Dhcp6Parser::yypgoto_[] =
{
-824, -824, -824, -824, -824, -824, -824, -824, -824, -824,
-824
};
- const short int
+ const short
Dhcp6Parser::yydefgoto_[] =
{
-1, 16, 17, 18, 19, 20, 21, 22, 23, 24,
1080
};
- const unsigned short int
+ const unsigned short
Dhcp6Parser::yytable_[] =
{
100, 139, 174, 192, 215, 229, 249, 193, 271, 290,
0, 0, 0, 965
};
- const short int
+ const short
Dhcp6Parser::yycheck_[] =
{
74, 75, 76, 77, 78, 79, 80, 77, 82, 83,
-1, -1, -1, 1035
};
- const unsigned short int
+ const unsigned short
Dhcp6Parser::yystos_[] =
{
0, 156, 157, 158, 159, 160, 161, 162, 163, 164,
172, 172, 560, 171
};
- const unsigned short int
+ const unsigned short
Dhcp6Parser::yyr1_[] =
{
0, 175, 177, 176, 178, 176, 179, 176, 180, 176,
};
#if PARSER6_DEBUG
- const unsigned short int
+ const unsigned short
Dhcp6Parser::yyrline_[] =
{
0, 258, 258, 258, 259, 259, 260, 260, 261, 261,
#endif // PARSER6_DEBUG
-#line 14 "dhcp6_parser.yy" // lalr1.cc:1163
+#line 14 "dhcp6_parser.yy" // lalr1.cc:1218
} } // isc::dhcp
-#line 5044 "dhcp6_parser.cc" // lalr1.cc:1163
-#line 2339 "dhcp6_parser.yy" // lalr1.cc:1164
+#line 5071 "dhcp6_parser.cc" // lalr1.cc:1218
+#line 2339 "dhcp6_parser.yy" // lalr1.cc:1219
void
-// A Bison parser, made by GNU Bison 3.0.5.
+// A Bison parser, made by GNU Bison 3.2.1.
// Skeleton interface for Bison LALR(1) parsers in C++
// This special exception was added by the Free Software Foundation in
// version 2.2 of Bison.
+
/**
** \file dhcp6_parser.h
** Define the isc::dhcp::parser class.
// C++ LALR(1) parser skeleton written by Akim Demaille.
+// Undocumented macros, especially those whose name start with YY_,
+// are private implementation details. Do not rely on them.
+
#ifndef YY_PARSER6_DHCP6_PARSER_H_INCLUDED
# define YY_PARSER6_DHCP6_PARSER_H_INCLUDED
// // "%code requires" blocks.
-#line 17 "dhcp6_parser.yy" // lalr1.cc:379
+#line 17 "dhcp6_parser.yy" // lalr1.cc:404
#include <string>
#include <cc/data.h>
using namespace isc::data;
using namespace std;
-#line 56 "dhcp6_parser.h" // lalr1.cc:379
+#line 60 "dhcp6_parser.h" // lalr1.cc:404
# include <cassert>
# include <cstdlib> // std::abort
# include <stdexcept>
# include <string>
# include <vector>
-# include "stack.hh"
+
+// Support move semantics when possible.
+#if defined __cplusplus && 201103L <= __cplusplus
+# define YY_MOVE std::move
+# define YY_MOVE_OR_COPY move
+# define YY_MOVE_REF(Type) Type&&
+# define YY_RVREF(Type) Type&&
+# define YY_COPY(Type) Type
+#else
+# define YY_MOVE
+# define YY_MOVE_OR_COPY copy
+# define YY_MOVE_REF(Type) Type&
+# define YY_RVREF(Type) const Type&
+# define YY_COPY(Type) const Type&
+#endif
# include "location.hh"
#include <typeinfo>
#ifndef YYASSERT
# define YY_ATTRIBUTE_UNUSED YY_ATTRIBUTE ((__unused__))
#endif
-#if !defined _Noreturn \
- && (!defined __STDC_VERSION__ || __STDC_VERSION__ < 201112)
-# if defined _MSC_VER && 1200 <= _MSC_VER
-# define _Noreturn __declspec (noreturn)
-# else
-# define _Noreturn YY_ATTRIBUTE ((__noreturn__))
-# endif
-#endif
-
/* Suppress unused-variable warnings by "using" E. */
#if ! defined lint || defined __GNUC__
# define YYUSE(E) ((void) (E))
# define YYUSE(E) /* empty */
#endif
-#if defined __GNUC__ && 407 <= __GNUC__ * 100 + __GNUC_MINOR__
+#if defined __GNUC__ && ! defined __ICC && 407 <= __GNUC__ * 100 + __GNUC_MINOR__
/* Suppress an incorrect diagnostic about yylval being uninitialized. */
# define YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN \
_Pragma ("GCC diagnostic push") \
# define YY_INITIAL_VALUE(Value) /* Nothing. */
#endif
+# ifndef YY_NULLPTR
+# if defined __cplusplus
+# if 201103L <= __cplusplus
+# define YY_NULLPTR nullptr
+# else
+# define YY_NULLPTR 0
+# endif
+# else
+# define YY_NULLPTR ((void*)0)
+# endif
+# endif
+
/* Debug traces. */
#ifndef PARSER6_DEBUG
# if defined YYDEBUG
# endif /* ! defined YYDEBUG */
#endif /* ! defined PARSER6_DEBUG */
-#line 14 "dhcp6_parser.yy" // lalr1.cc:379
+#line 14 "dhcp6_parser.yy" // lalr1.cc:404
namespace isc { namespace dhcp {
-#line 141 "dhcp6_parser.h" // lalr1.cc:379
+#line 162 "dhcp6_parser.h" // lalr1.cc:404
+
+ /// A stack with random access from its top.
+ template <typename T, typename S = std::vector<T> >
+ class stack
+ {
+ public:
+ // Hide our reversed order.
+ typedef typename S::reverse_iterator iterator;
+ typedef typename S::const_reverse_iterator const_iterator;
+ typedef typename S::size_type size_type;
+
+ stack (size_type n = 200)
+ : seq_ (n)
+ {}
+
+ /// Random access.
+ ///
+ /// Index 0 returns the topmost element.
+ T&
+ operator[] (size_type i)
+ {
+ return seq_[size () - 1 - i];
+ }
+
+ /// Random access.
+ ///
+ /// Index 0 returns the topmost element.
+ T&
+ operator[] (int i)
+ {
+ return operator[] (size_type (i));
+ }
+
+ /// Random access.
+ ///
+ /// Index 0 returns the topmost element.
+ const T&
+ operator[] (size_type i) const
+ {
+ return seq_[size () - 1 - i];
+ }
+
+ /// Random access.
+ ///
+ /// Index 0 returns the topmost element.
+ const T&
+ operator[] (int i) const
+ {
+ return operator[] (size_type (i));
+ }
+
+ /// Steal the contents of \a t.
+ ///
+ /// Close to move-semantics.
+ void
+ push (YY_MOVE_REF (T) t)
+ {
+ seq_.push_back (T ());
+ operator[](0).move (t);
+ }
+
+ void
+ pop (int n = 1)
+ {
+ for (; 0 < n; --n)
+ seq_.pop_back ();
+ }
+
+ void
+ clear ()
+ {
+ seq_.clear ();
+ }
+
+ size_type
+ size () const
+ {
+ return seq_.size ();
+ }
+
+ const_iterator
+ begin () const
+ {
+ return seq_.rbegin ();
+ }
+
+ const_iterator
+ end () const
+ {
+ return seq_.rend ();
+ }
+
+ private:
+ stack (const stack&);
+ stack& operator= (const stack&);
+ /// The wrapped container.
+ S seq_;
+ };
+
+ /// Present a slice of the top of a stack.
+ template <typename T, typename S = stack<T> >
+ class slice
+ {
+ public:
+ slice (const S& stack, int range)
+ : stack_ (stack)
+ , range_ (range)
+ {}
+
+ const T&
+ operator[] (int i) const
+ {
+ return stack_[range_ - i];
+ }
+
+ private:
+ const S& stack_;
+ int range_;
+ };
/// Empty construction.
variant ()
- : yytypeid_ (YY_NULLPTR)
+ : yybuffer_ ()
+ , yytypeid_ (YY_NULLPTR)
{}
/// Construct and fill.
template <typename T>
- variant (const T& t)
+ variant (YY_RVREF (T) t)
: yytypeid_ (&typeid (T))
{
YYASSERT (sizeof (T) <= S);
- new (yyas_<T> ()) T (t);
+ new (yyas_<T> ()) T (YY_MOVE (t));
}
/// Destruction, allowed only if empty.
/// Instantiate an empty \a T in here.
template <typename T>
T&
- build ()
+ emplace ()
{
YYASSERT (!yytypeid_);
YYASSERT (sizeof (T) <= S);
yytypeid_ = & typeid (T);
- return *new (yyas_<T> ()) T;
+ return *new (yyas_<T> ()) T ();
}
+# if defined __cplusplus && 201103L <= __cplusplus
+ /// Instantiate a \a T in here from \a t.
+ template <typename T, typename U>
+ T&
+ emplace (U&& u)
+ {
+ YYASSERT (!yytypeid_);
+ YYASSERT (sizeof (T) <= S);
+ yytypeid_ = & typeid (T);
+ return *new (yyas_<T> ()) T (std::forward <U>(u));
+ }
+# else
/// Instantiate a \a T in here from \a t.
template <typename T>
T&
- build (const T& t)
+ emplace (const T& t)
{
YYASSERT (!yytypeid_);
YYASSERT (sizeof (T) <= S);
yytypeid_ = & typeid (T);
return *new (yyas_<T> ()) T (t);
}
+# endif
+
+ /// Instantiate an empty \a T in here.
+ /// Obsolete, use emplace.
+ template <typename T>
+ T&
+ build ()
+ {
+ return emplace<T> ();
+ }
+
+ /// Instantiate a \a T in here from \a t.
+ /// Obsolete, use emplace.
+ template <typename T>
+ T&
+ build (const T& t)
+ {
+ return emplace<T> (t);
+ }
/// Accessor to a built \a T.
template <typename T>
T&
as ()
{
+ YYASSERT (yytypeid_);
YYASSERT (*yytypeid_ == typeid (T));
YYASSERT (sizeof (T) <= S);
return *yyas_<T> ();
const T&
as () const
{
+ YYASSERT (yytypeid_);
YYASSERT (*yytypeid_ == typeid (T));
YYASSERT (sizeof (T) <= S);
return *yyas_<T> ();
/// Both variants must be built beforehand, because swapping the actual
/// data requires reading it (with as()), and this is not possible on
/// unconstructed variants: it would require some dynamic testing, which
- /// should not be the variant's responsability.
+ /// should not be the variant's responsibility.
/// Swapping between built and (possibly) non-built is done with
/// variant::move ().
template <typename T>
void
move (self_type& other)
{
- build<T> ();
+# if defined __cplusplus && 201103L <= __cplusplus
+ emplace<T> (std::move (other.as<T> ()));
+# else
+ emplace<T> ();
swap<T> (other);
+# endif
+ other.destroy<T> ();
+ }
+
+# if defined __cplusplus && 201103L <= __cplusplus
+ /// Move the content of \a other to this.
+ template <typename T>
+ void
+ move (self_type&& other)
+ {
+ emplace<T> (std::move (other.as<T> ()));
other.destroy<T> ();
}
+#endif
/// Copy the content of \a other to this.
template <typename T>
void
copy (const self_type& other)
{
- build<T> (other.as<T> ());
+ emplace<T> (other.as<T> ());
}
/// Destroy the stored \a T.
private:
/// Prohibit blind copies.
- self_type& operator=(const self_type&);
+ self_type& operator= (const self_type&);
variant (const self_type&);
/// Accessor to raw memory as \a T.
// duid_type
// ncr_protocol_value
// replace_client_name_value
- char dummy1[sizeof(ElementPtr)];
+ char dummy1[sizeof (ElementPtr)];
// "boolean"
- char dummy2[sizeof(bool)];
+ char dummy2[sizeof (bool)];
// "floating point"
- char dummy3[sizeof(double)];
+ char dummy3[sizeof (double)];
// "integer"
- char dummy4[sizeof(int64_t)];
+ char dummy4[sizeof (int64_t)];
// "constant string"
- char dummy5[sizeof(std::string)];
+ char dummy5[sizeof (std::string)];
};
/// Symbol semantic values.
- typedef variant<sizeof(union_type)> semantic_type;
+ typedef variant<sizeof (union_type)> semantic_type;
#else
typedef PARSER6_STYPE semantic_type;
#endif
/// A complete symbol.
///
/// Expects its Base type to provide access to the symbol type
- /// via type_get().
+ /// via type_get ().
///
/// Provide access to semantic value and location.
template <typename Base>
/// Default constructor.
basic_symbol ();
- /// Copy constructor.
- basic_symbol (const basic_symbol& other);
-
- /// Constructor for valueless symbols, and symbols from each type.
-
- basic_symbol (typename Base::kind_type t, const location_type& l);
-
- basic_symbol (typename Base::kind_type t, const ElementPtr v, const location_type& l);
-
- basic_symbol (typename Base::kind_type t, const bool v, const location_type& l);
-
- basic_symbol (typename Base::kind_type t, const double v, const location_type& l);
-
- basic_symbol (typename Base::kind_type t, const int64_t v, const location_type& l);
+ /// Move or copy constructor.
+ basic_symbol (YY_RVREF (basic_symbol) other);
- basic_symbol (typename Base::kind_type t, const std::string v, const location_type& l);
+ /// Constructor for valueless symbols, and symbols from each type.
+ basic_symbol (typename Base::kind_type t, YY_RVREF (location_type) l);
+ basic_symbol (typename Base::kind_type t, YY_RVREF (ElementPtr) v, YY_RVREF (location_type) l);
+ basic_symbol (typename Base::kind_type t, YY_RVREF (bool) v, YY_RVREF (location_type) l);
+ basic_symbol (typename Base::kind_type t, YY_RVREF (double) v, YY_RVREF (location_type) l);
+ basic_symbol (typename Base::kind_type t, YY_RVREF (int64_t) v, YY_RVREF (location_type) l);
+ basic_symbol (typename Base::kind_type t, YY_RVREF (std::string) v, YY_RVREF (location_type) l);
- /// Constructor for symbols with semantic value.
- basic_symbol (typename Base::kind_type t,
- const semantic_type& v,
- const location_type& l);
/// Destroy the symbol.
~basic_symbol ();
location_type location;
private:
+#if !defined __cplusplus || __cplusplus < 201103L
/// Assignment operator.
basic_symbol& operator= (const basic_symbol& other);
+#endif
};
/// Type access provider for token (enum) based symbols.
/// "External" symbols: returned by the scanner.
typedef basic_symbol<by_type> symbol_type;
+ /// Build a parser object.
+ Dhcp6Parser (isc::dhcp::Parser6Context& ctx_yyarg);
+ virtual ~Dhcp6Parser ();
+
+ /// Parse. An alias for parse ().
+ /// \returns 0 iff parsing succeeded.
+ int operator() ();
+
+ /// Parse.
+ /// \returns 0 iff parsing succeeded.
+ virtual int parse ();
+
+#if PARSER6_DEBUG
+ /// The current debugging stream.
+ std::ostream& debug_stream () const YY_ATTRIBUTE_PURE;
+ /// Set the current debugging stream.
+ void set_debug_stream (std::ostream &);
+
+ /// Type for debugging levels.
+ typedef int debug_level_type;
+ /// The current debugging level.
+ debug_level_type debug_level () const YY_ATTRIBUTE_PURE;
+ /// Set the current debugging level.
+ void set_debug_level (debug_level_type l);
+#endif
+
+ /// Report a syntax error.
+ /// \param loc where the syntax error is found.
+ /// \param msg a description of the syntax error.
+ virtual void error (const location_type& loc, const std::string& msg);
+
+ /// Report a syntax error.
+ void error (const syntax_error& err);
+
// Symbol constructors declarations.
- static inline
+ static
symbol_type
- make_END (const location_type& l);
+ make_END (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_COMMA (const location_type& l);
+ make_COMMA (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_COLON (const location_type& l);
+ make_COLON (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_LSQUARE_BRACKET (const location_type& l);
+ make_LSQUARE_BRACKET (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_RSQUARE_BRACKET (const location_type& l);
+ make_RSQUARE_BRACKET (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_LCURLY_BRACKET (const location_type& l);
+ make_LCURLY_BRACKET (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_RCURLY_BRACKET (const location_type& l);
+ make_RCURLY_BRACKET (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_NULL_TYPE (const location_type& l);
+ make_NULL_TYPE (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_DHCP6 (const location_type& l);
+ make_DHCP6 (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_CONFIG_CONTROL (const location_type& l);
+ make_CONFIG_CONTROL (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_CONFIG_DATABASES (const location_type& l);
+ make_CONFIG_DATABASES (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_INTERFACES_CONFIG (const location_type& l);
+ make_INTERFACES_CONFIG (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_INTERFACES (const location_type& l);
+ make_INTERFACES (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_RE_DETECT (const location_type& l);
+ make_RE_DETECT (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_LEASE_DATABASE (const location_type& l);
+ make_LEASE_DATABASE (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_HOSTS_DATABASE (const location_type& l);
+ make_HOSTS_DATABASE (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_HOSTS_DATABASES (const location_type& l);
+ make_HOSTS_DATABASES (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_TYPE (const location_type& l);
+ make_TYPE (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_MEMFILE (const location_type& l);
+ make_MEMFILE (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_MYSQL (const location_type& l);
+ make_MYSQL (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_POSTGRESQL (const location_type& l);
+ make_POSTGRESQL (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_CQL (const location_type& l);
+ make_CQL (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_USER (const location_type& l);
+ make_USER (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_PASSWORD (const location_type& l);
+ make_PASSWORD (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_HOST (const location_type& l);
+ make_HOST (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_PORT (const location_type& l);
+ make_PORT (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_PERSIST (const location_type& l);
+ make_PERSIST (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_LFC_INTERVAL (const location_type& l);
+ make_LFC_INTERVAL (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_READONLY (const location_type& l);
+ make_READONLY (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_CONNECT_TIMEOUT (const location_type& l);
+ make_CONNECT_TIMEOUT (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_CONTACT_POINTS (const location_type& l);
+ make_CONTACT_POINTS (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_MAX_RECONNECT_TRIES (const location_type& l);
+ make_MAX_RECONNECT_TRIES (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_RECONNECT_WAIT_TIME (const location_type& l);
+ make_RECONNECT_WAIT_TIME (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_KEYSPACE (const location_type& l);
+ make_KEYSPACE (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_REQUEST_TIMEOUT (const location_type& l);
+ make_REQUEST_TIMEOUT (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_TCP_KEEPALIVE (const location_type& l);
+ make_TCP_KEEPALIVE (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_TCP_NODELAY (const location_type& l);
+ make_TCP_NODELAY (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_PREFERRED_LIFETIME (const location_type& l);
+ make_PREFERRED_LIFETIME (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_VALID_LIFETIME (const location_type& l);
+ make_VALID_LIFETIME (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_RENEW_TIMER (const location_type& l);
+ make_RENEW_TIMER (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_REBIND_TIMER (const location_type& l);
+ make_REBIND_TIMER (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_DECLINE_PROBATION_PERIOD (const location_type& l);
+ make_DECLINE_PROBATION_PERIOD (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_SERVER_TAG (const location_type& l);
+ make_SERVER_TAG (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_SUBNET6 (const location_type& l);
+ make_SUBNET6 (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_OPTION_DEF (const location_type& l);
+ make_OPTION_DEF (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_OPTION_DATA (const location_type& l);
+ make_OPTION_DATA (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_NAME (const location_type& l);
+ make_NAME (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_DATA (const location_type& l);
+ make_DATA (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_CODE (const location_type& l);
+ make_CODE (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_SPACE (const location_type& l);
+ make_SPACE (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_CSV_FORMAT (const location_type& l);
+ make_CSV_FORMAT (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_ALWAYS_SEND (const location_type& l);
+ make_ALWAYS_SEND (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_RECORD_TYPES (const location_type& l);
+ make_RECORD_TYPES (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_ENCAPSULATE (const location_type& l);
+ make_ENCAPSULATE (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_ARRAY (const location_type& l);
+ make_ARRAY (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_POOLS (const location_type& l);
+ make_POOLS (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_POOL (const location_type& l);
+ make_POOL (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_PD_POOLS (const location_type& l);
+ make_PD_POOLS (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_PREFIX (const location_type& l);
+ make_PREFIX (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_PREFIX_LEN (const location_type& l);
+ make_PREFIX_LEN (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_EXCLUDED_PREFIX (const location_type& l);
+ make_EXCLUDED_PREFIX (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_EXCLUDED_PREFIX_LEN (const location_type& l);
+ make_EXCLUDED_PREFIX_LEN (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_DELEGATED_LEN (const location_type& l);
+ make_DELEGATED_LEN (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_USER_CONTEXT (const location_type& l);
+ make_USER_CONTEXT (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_COMMENT (const location_type& l);
+ make_COMMENT (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_SUBNET (const location_type& l);
+ make_SUBNET (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_INTERFACE (const location_type& l);
+ make_INTERFACE (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_INTERFACE_ID (const location_type& l);
+ make_INTERFACE_ID (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_ID (const location_type& l);
+ make_ID (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_RAPID_COMMIT (const location_type& l);
+ make_RAPID_COMMIT (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_RESERVATION_MODE (const location_type& l);
+ make_RESERVATION_MODE (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_DISABLED (const location_type& l);
+ make_DISABLED (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_OUT_OF_POOL (const location_type& l);
+ make_OUT_OF_POOL (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_GLOBAL (const location_type& l);
+ make_GLOBAL (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_ALL (const location_type& l);
+ make_ALL (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_SHARED_NETWORKS (const location_type& l);
+ make_SHARED_NETWORKS (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_MAC_SOURCES (const location_type& l);
+ make_MAC_SOURCES (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_RELAY_SUPPLIED_OPTIONS (const location_type& l);
+ make_RELAY_SUPPLIED_OPTIONS (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_HOST_RESERVATION_IDENTIFIERS (const location_type& l);
+ make_HOST_RESERVATION_IDENTIFIERS (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_SANITY_CHECKS (const location_type& l);
+ make_SANITY_CHECKS (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_LEASE_CHECKS (const location_type& l);
+ make_LEASE_CHECKS (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_CLIENT_CLASSES (const location_type& l);
+ make_CLIENT_CLASSES (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_REQUIRE_CLIENT_CLASSES (const location_type& l);
+ make_REQUIRE_CLIENT_CLASSES (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_TEST (const location_type& l);
+ make_TEST (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_ONLY_IF_REQUIRED (const location_type& l);
+ make_ONLY_IF_REQUIRED (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_CLIENT_CLASS (const location_type& l);
+ make_CLIENT_CLASS (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_RESERVATIONS (const location_type& l);
+ make_RESERVATIONS (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_IP_ADDRESSES (const location_type& l);
+ make_IP_ADDRESSES (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_PREFIXES (const location_type& l);
+ make_PREFIXES (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_DUID (const location_type& l);
+ make_DUID (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_HW_ADDRESS (const location_type& l);
+ make_HW_ADDRESS (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_HOSTNAME (const location_type& l);
+ make_HOSTNAME (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_FLEX_ID (const location_type& l);
+ make_FLEX_ID (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_RELAY (const location_type& l);
+ make_RELAY (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_IP_ADDRESS (const location_type& l);
+ make_IP_ADDRESS (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_HOOKS_LIBRARIES (const location_type& l);
+ make_HOOKS_LIBRARIES (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_LIBRARY (const location_type& l);
+ make_LIBRARY (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_PARAMETERS (const location_type& l);
+ make_PARAMETERS (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_EXPIRED_LEASES_PROCESSING (const location_type& l);
+ make_EXPIRED_LEASES_PROCESSING (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_RECLAIM_TIMER_WAIT_TIME (const location_type& l);
+ make_RECLAIM_TIMER_WAIT_TIME (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_FLUSH_RECLAIMED_TIMER_WAIT_TIME (const location_type& l);
+ make_FLUSH_RECLAIMED_TIMER_WAIT_TIME (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_HOLD_RECLAIMED_TIME (const location_type& l);
+ make_HOLD_RECLAIMED_TIME (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_MAX_RECLAIM_LEASES (const location_type& l);
+ make_MAX_RECLAIM_LEASES (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_MAX_RECLAIM_TIME (const location_type& l);
+ make_MAX_RECLAIM_TIME (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_UNWARNED_RECLAIM_CYCLES (const location_type& l);
+ make_UNWARNED_RECLAIM_CYCLES (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_SERVER_ID (const location_type& l);
+ make_SERVER_ID (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_LLT (const location_type& l);
+ make_LLT (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_EN (const location_type& l);
+ make_EN (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_LL (const location_type& l);
+ make_LL (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_IDENTIFIER (const location_type& l);
+ make_IDENTIFIER (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_HTYPE (const location_type& l);
+ make_HTYPE (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_TIME (const location_type& l);
+ make_TIME (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_ENTERPRISE_ID (const location_type& l);
+ make_ENTERPRISE_ID (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_DHCP4O6_PORT (const location_type& l);
+ make_DHCP4O6_PORT (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_CONTROL_SOCKET (const location_type& l);
+ make_CONTROL_SOCKET (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_SOCKET_TYPE (const location_type& l);
+ make_SOCKET_TYPE (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_SOCKET_NAME (const location_type& l);
+ make_SOCKET_NAME (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_DHCP_QUEUE_CONTROL (const location_type& l);
+ make_DHCP_QUEUE_CONTROL (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_DHCP_DDNS (const location_type& l);
+ make_DHCP_DDNS (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_ENABLE_UPDATES (const location_type& l);
+ make_ENABLE_UPDATES (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_QUALIFYING_SUFFIX (const location_type& l);
+ make_QUALIFYING_SUFFIX (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_SERVER_IP (const location_type& l);
+ make_SERVER_IP (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_SERVER_PORT (const location_type& l);
+ make_SERVER_PORT (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_SENDER_IP (const location_type& l);
+ make_SENDER_IP (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_SENDER_PORT (const location_type& l);
+ make_SENDER_PORT (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_MAX_QUEUE_SIZE (const location_type& l);
+ make_MAX_QUEUE_SIZE (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_NCR_PROTOCOL (const location_type& l);
+ make_NCR_PROTOCOL (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_NCR_FORMAT (const location_type& l);
+ make_NCR_FORMAT (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_ALWAYS_INCLUDE_FQDN (const location_type& l);
+ make_ALWAYS_INCLUDE_FQDN (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_OVERRIDE_NO_UPDATE (const location_type& l);
+ make_OVERRIDE_NO_UPDATE (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_OVERRIDE_CLIENT_UPDATE (const location_type& l);
+ make_OVERRIDE_CLIENT_UPDATE (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_REPLACE_CLIENT_NAME (const location_type& l);
+ make_REPLACE_CLIENT_NAME (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_GENERATED_PREFIX (const location_type& l);
+ make_GENERATED_PREFIX (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_UDP (const location_type& l);
+ make_UDP (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_TCP (const location_type& l);
+ make_TCP (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_JSON (const location_type& l);
+ make_JSON (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_WHEN_PRESENT (const location_type& l);
+ make_WHEN_PRESENT (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_NEVER (const location_type& l);
+ make_NEVER (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_ALWAYS (const location_type& l);
+ make_ALWAYS (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_WHEN_NOT_PRESENT (const location_type& l);
+ make_WHEN_NOT_PRESENT (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_HOSTNAME_CHAR_SET (const location_type& l);
+ make_HOSTNAME_CHAR_SET (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_HOSTNAME_CHAR_REPLACEMENT (const location_type& l);
+ make_HOSTNAME_CHAR_REPLACEMENT (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_LOGGING (const location_type& l);
+ make_LOGGING (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_LOGGERS (const location_type& l);
+ make_LOGGERS (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_OUTPUT_OPTIONS (const location_type& l);
+ make_OUTPUT_OPTIONS (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_OUTPUT (const location_type& l);
+ make_OUTPUT (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_DEBUGLEVEL (const location_type& l);
+ make_DEBUGLEVEL (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_SEVERITY (const location_type& l);
+ make_SEVERITY (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_FLUSH (const location_type& l);
+ make_FLUSH (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_MAXSIZE (const location_type& l);
+ make_MAXSIZE (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_MAXVER (const location_type& l);
+ make_MAXVER (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_DHCP4 (const location_type& l);
+ make_DHCP4 (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_DHCPDDNS (const location_type& l);
+ make_DHCPDDNS (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_CONTROL_AGENT (const location_type& l);
+ make_CONTROL_AGENT (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_TOPLEVEL_JSON (const location_type& l);
+ make_TOPLEVEL_JSON (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_TOPLEVEL_DHCP6 (const location_type& l);
+ make_TOPLEVEL_DHCP6 (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_SUB_DHCP6 (const location_type& l);
+ make_SUB_DHCP6 (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_SUB_INTERFACES6 (const location_type& l);
+ make_SUB_INTERFACES6 (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_SUB_SUBNET6 (const location_type& l);
+ make_SUB_SUBNET6 (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_SUB_POOL6 (const location_type& l);
+ make_SUB_POOL6 (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_SUB_PD_POOL (const location_type& l);
+ make_SUB_PD_POOL (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_SUB_RESERVATION (const location_type& l);
+ make_SUB_RESERVATION (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_SUB_OPTION_DEFS (const location_type& l);
+ make_SUB_OPTION_DEFS (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_SUB_OPTION_DEF (const location_type& l);
+ make_SUB_OPTION_DEF (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_SUB_OPTION_DATA (const location_type& l);
+ make_SUB_OPTION_DATA (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_SUB_HOOKS_LIBRARY (const location_type& l);
+ make_SUB_HOOKS_LIBRARY (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_SUB_DHCP_DDNS (const location_type& l);
+ make_SUB_DHCP_DDNS (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_SUB_LOGGING (const location_type& l);
+ make_SUB_LOGGING (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_SUB_CONFIG_CONTROL (const location_type& l);
+ make_SUB_CONFIG_CONTROL (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_STRING (const std::string& v, const location_type& l);
+ make_STRING (YY_COPY (std::string) v, YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_INTEGER (const int64_t& v, const location_type& l);
+ make_INTEGER (YY_COPY (int64_t) v, YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_FLOAT (const double& v, const location_type& l);
+ make_FLOAT (YY_COPY (double) v, YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_BOOLEAN (const bool& v, const location_type& l);
-
-
- /// Build a parser object.
- Dhcp6Parser (isc::dhcp::Parser6Context& ctx_yyarg);
- virtual ~Dhcp6Parser ();
-
- /// Parse.
- /// \returns 0 iff parsing succeeded.
- virtual int parse ();
-
-#if PARSER6_DEBUG
- /// The current debugging stream.
- std::ostream& debug_stream () const YY_ATTRIBUTE_PURE;
- /// Set the current debugging stream.
- void set_debug_stream (std::ostream &);
-
- /// Type for debugging levels.
- typedef int debug_level_type;
- /// The current debugging level.
- debug_level_type debug_level () const YY_ATTRIBUTE_PURE;
- /// Set the current debugging level.
- void set_debug_level (debug_level_type l);
-#endif
+ make_BOOLEAN (YY_COPY (bool) v, YY_COPY (location_type) l);
- /// Report a syntax error.
- /// \param loc where the syntax error is found.
- /// \param msg a description of the syntax error.
- virtual void error (const location_type& loc, const std::string& msg);
- /// Report a syntax error.
- void error (const syntax_error& err);
private:
/// This class is not copyable.
/// \param yyvalue the value to check
static bool yy_table_value_is_error_ (int yyvalue);
- static const short int yypact_ninf_;
+ static const short yypact_ninf_;
static const signed char yytable_ninf_;
/// Convert a scanner token number \a t to a symbol number.
// Tables.
// YYPACT[STATE-NUM] -- Index in YYTABLE of the portion describing
// STATE-NUM.
- static const short int yypact_[];
+ static const short yypact_[];
// YYDEFACT[STATE-NUM] -- Default reduction number in state STATE-NUM.
// Performed when YYTABLE does not specify something else to do. Zero
// means the default is an error.
- static const unsigned short int yydefact_[];
+ static const unsigned short yydefact_[];
// YYPGOTO[NTERM-NUM].
- static const short int yypgoto_[];
+ static const short yypgoto_[];
// YYDEFGOTO[NTERM-NUM].
- static const short int yydefgoto_[];
+ static const short yydefgoto_[];
// YYTABLE[YYPACT[STATE-NUM]] -- What to do in state STATE-NUM. If
// positive, shift that token. If negative, reduce the rule whose
// number is the opposite. If YYTABLE_NINF, syntax error.
- static const unsigned short int yytable_[];
+ static const unsigned short yytable_[];
- static const short int yycheck_[];
+ static const short yycheck_[];
// YYSTOS[STATE-NUM] -- The (internal number of the) accessing
// symbol of state STATE-NUM.
- static const unsigned short int yystos_[];
+ static const unsigned short yystos_[];
// YYR1[YYN] -- Symbol number of symbol that rule YYN derives.
- static const unsigned short int yyr1_[];
+ static const unsigned short yyr1_[];
// YYR2[YYN] -- Number of symbols on the right hand side of rule YYN.
static const unsigned char yyr2_[];
static const char* const yytname_[];
#if PARSER6_DEBUG
// YYRLINE[YYN] -- Source line where rule number YYN was defined.
- static const unsigned short int yyrline_[];
+ static const unsigned short yyrline_[];
/// Report on the debug stream that the rule \a r is going to be reduced.
virtual void yy_reduce_print_ (int r);
/// Print the state stack on the debug stream.
virtual void yystack_print_ ();
- // Debugging.
+ /// Debugging level.
int yydebug_;
+ /// Debug stream.
std::ostream* yycdebug_;
/// \brief Display a symbol type, value and location.
typedef basic_symbol<by_state> super_type;
/// Construct an empty symbol.
stack_symbol_type ();
- /// Copy construct.
- stack_symbol_type (const stack_symbol_type& that);
+ /// Move or copy construction.
+ stack_symbol_type (YY_RVREF (stack_symbol_type) that);
/// Steal the contents from \a sym to build this.
- stack_symbol_type (state_type s, symbol_type& sym);
- /// Assignment, needed by push_back.
- stack_symbol_type& operator= (const stack_symbol_type& that);
+ stack_symbol_type (state_type s, YY_MOVE_REF (symbol_type) sym);
+#if !defined __cplusplus || __cplusplus < 201103L
+ /// Assignment, needed by push_back by some old implementations.
+ /// Moves the contents of that.
+ stack_symbol_type& operator= (stack_symbol_type& that);
+#endif
};
/// Stack type.
/// Push a new state on the stack.
/// \param m a debug message to display
/// if null, no trace is output.
- /// \param s the symbol
+ /// \param sym the symbol
/// \warning the contents of \a s.value is stolen.
- void yypush_ (const char* m, stack_symbol_type& s);
+ void yypush_ (const char* m, YY_MOVE_REF (stack_symbol_type) sym);
/// Push a new look ahead token on the state on the stack.
/// \param m a debug message to display
/// if null, no trace is output.
/// \param s the state
/// \param sym the symbol (for its value and location).
- /// \warning the contents of \a s.value is stolen.
- void yypush_ (const char* m, state_type s, symbol_type& sym);
+ /// \warning the contents of \a sym.value is stolen.
+ void yypush_ (const char* m, state_type s, YY_MOVE_REF (symbol_type) sym);
- /// Pop \a n symbols the three stacks.
- void yypop_ (unsigned n = 1);
+ /// Pop \a n symbols from the stack.
+ void yypop_ (int n = 1);
/// Constants.
enum
template <typename Base>
Dhcp6Parser::basic_symbol<Base>::basic_symbol ()
: value ()
+ , location ()
{}
template <typename Base>
- Dhcp6Parser::basic_symbol<Base>::basic_symbol (const basic_symbol& other)
- : Base (other)
+ Dhcp6Parser::basic_symbol<Base>::basic_symbol (YY_RVREF (basic_symbol) other)
+ : Base (YY_MOVE (other))
, value ()
- , location (other.location)
+ , location (YY_MOVE (other.location))
{
switch (other.type_get ())
{
case 473: // duid_type
case 508: // ncr_protocol_value
case 516: // replace_client_name_value
- value.copy< ElementPtr > (other.value);
+ value.YY_MOVE_OR_COPY< ElementPtr > (YY_MOVE (other.value));
break;
case 174: // "boolean"
- value.copy< bool > (other.value);
+ value.YY_MOVE_OR_COPY< bool > (YY_MOVE (other.value));
break;
case 173: // "floating point"
- value.copy< double > (other.value);
+ value.YY_MOVE_OR_COPY< double > (YY_MOVE (other.value));
break;
case 172: // "integer"
- value.copy< int64_t > (other.value);
+ value.YY_MOVE_OR_COPY< int64_t > (YY_MOVE (other.value));
break;
case 171: // "constant string"
- value.copy< std::string > (other.value);
+ value.YY_MOVE_OR_COPY< std::string > (YY_MOVE (other.value));
break;
default:
}
- template <typename Base>
- Dhcp6Parser::basic_symbol<Base>::basic_symbol (typename Base::kind_type t, const semantic_type& v, const location_type& l)
- : Base (t)
- , value ()
- , location (l)
- {
- (void) v;
- switch (this->type_get ())
- {
- case 192: // value
- case 196: // map_value
- case 248: // db_type
- case 337: // hr_mode
- case 473: // duid_type
- case 508: // ncr_protocol_value
- case 516: // replace_client_name_value
- value.copy< ElementPtr > (v);
- break;
-
- case 174: // "boolean"
- value.copy< bool > (v);
- break;
-
- case 173: // "floating point"
- value.copy< double > (v);
- break;
-
- case 172: // "integer"
- value.copy< int64_t > (v);
- break;
-
- case 171: // "constant string"
- value.copy< std::string > (v);
- break;
-
- default:
- break;
- }
-}
-
// Implementation of basic_symbol constructor for each type.
-
template <typename Base>
- Dhcp6Parser::basic_symbol<Base>::basic_symbol (typename Base::kind_type t, const location_type& l)
+ Dhcp6Parser::basic_symbol<Base>::basic_symbol (typename Base::kind_type t, YY_RVREF (location_type) l)
: Base (t)
- , value ()
- , location (l)
+ , location (YY_MOVE (l))
{}
template <typename Base>
- Dhcp6Parser::basic_symbol<Base>::basic_symbol (typename Base::kind_type t, const ElementPtr v, const location_type& l)
+ Dhcp6Parser::basic_symbol<Base>::basic_symbol (typename Base::kind_type t, YY_RVREF (ElementPtr) v, YY_RVREF (location_type) l)
: Base (t)
- , value (v)
- , location (l)
+ , value (YY_MOVE (v))
+ , location (YY_MOVE (l))
{}
template <typename Base>
- Dhcp6Parser::basic_symbol<Base>::basic_symbol (typename Base::kind_type t, const bool v, const location_type& l)
+ Dhcp6Parser::basic_symbol<Base>::basic_symbol (typename Base::kind_type t, YY_RVREF (bool) v, YY_RVREF (location_type) l)
: Base (t)
- , value (v)
- , location (l)
+ , value (YY_MOVE (v))
+ , location (YY_MOVE (l))
{}
template <typename Base>
- Dhcp6Parser::basic_symbol<Base>::basic_symbol (typename Base::kind_type t, const double v, const location_type& l)
+ Dhcp6Parser::basic_symbol<Base>::basic_symbol (typename Base::kind_type t, YY_RVREF (double) v, YY_RVREF (location_type) l)
: Base (t)
- , value (v)
- , location (l)
+ , value (YY_MOVE (v))
+ , location (YY_MOVE (l))
{}
template <typename Base>
- Dhcp6Parser::basic_symbol<Base>::basic_symbol (typename Base::kind_type t, const int64_t v, const location_type& l)
+ Dhcp6Parser::basic_symbol<Base>::basic_symbol (typename Base::kind_type t, YY_RVREF (int64_t) v, YY_RVREF (location_type) l)
: Base (t)
- , value (v)
- , location (l)
+ , value (YY_MOVE (v))
+ , location (YY_MOVE (l))
{}
template <typename Base>
- Dhcp6Parser::basic_symbol<Base>::basic_symbol (typename Base::kind_type t, const std::string v, const location_type& l)
+ Dhcp6Parser::basic_symbol<Base>::basic_symbol (typename Base::kind_type t, YY_RVREF (std::string) v, YY_RVREF (location_type) l)
: Base (t)
- , value (v)
- , location (l)
+ , value (YY_MOVE (v))
+ , location (YY_MOVE (l))
{}
+
template <typename Base>
Dhcp6Parser::basic_symbol<Base>::~basic_symbol ()
{
case 473: // duid_type
case 508: // ncr_protocol_value
case 516: // replace_client_name_value
- value.move< ElementPtr > (s.value);
+ value.move< ElementPtr > (YY_MOVE (s.value));
break;
case 174: // "boolean"
- value.move< bool > (s.value);
+ value.move< bool > (YY_MOVE (s.value));
break;
case 173: // "floating point"
- value.move< double > (s.value);
+ value.move< double > (YY_MOVE (s.value));
break;
case 172: // "integer"
- value.move< int64_t > (s.value);
+ value.move< int64_t > (YY_MOVE (s.value));
break;
case 171: // "constant string"
- value.move< std::string > (s.value);
+ value.move< std::string > (YY_MOVE (s.value));
break;
default:
break;
}
- location = s.location;
+ location = YY_MOVE (s.location);
}
// by_type.
// YYTOKNUM[NUM] -- (External) token number corresponding to the
// (internal) symbol number NUM (which must be that of a token). */
static
- const unsigned short int
+ const unsigned short
yytoken_number_[] =
{
0, 256, 257, 258, 259, 260, 261, 262, 263, 264,
};
return static_cast<token_type> (yytoken_number_[type]);
}
+
// Implementation of make_symbol for each symbol type.
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_END (const location_type& l)
+ Dhcp6Parser::make_END (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_END, l);
+ return symbol_type (token::TOKEN_END, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_COMMA (const location_type& l)
+ Dhcp6Parser::make_COMMA (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_COMMA, l);
+ return symbol_type (token::TOKEN_COMMA, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_COLON (const location_type& l)
+ Dhcp6Parser::make_COLON (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_COLON, l);
+ return symbol_type (token::TOKEN_COLON, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_LSQUARE_BRACKET (const location_type& l)
+ Dhcp6Parser::make_LSQUARE_BRACKET (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_LSQUARE_BRACKET, l);
+ return symbol_type (token::TOKEN_LSQUARE_BRACKET, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_RSQUARE_BRACKET (const location_type& l)
+ Dhcp6Parser::make_RSQUARE_BRACKET (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_RSQUARE_BRACKET, l);
+ return symbol_type (token::TOKEN_RSQUARE_BRACKET, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_LCURLY_BRACKET (const location_type& l)
+ Dhcp6Parser::make_LCURLY_BRACKET (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_LCURLY_BRACKET, l);
+ return symbol_type (token::TOKEN_LCURLY_BRACKET, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_RCURLY_BRACKET (const location_type& l)
+ Dhcp6Parser::make_RCURLY_BRACKET (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_RCURLY_BRACKET, l);
+ return symbol_type (token::TOKEN_RCURLY_BRACKET, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_NULL_TYPE (const location_type& l)
+ Dhcp6Parser::make_NULL_TYPE (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_NULL_TYPE, l);
+ return symbol_type (token::TOKEN_NULL_TYPE, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_DHCP6 (const location_type& l)
+ Dhcp6Parser::make_DHCP6 (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_DHCP6, l);
+ return symbol_type (token::TOKEN_DHCP6, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_CONFIG_CONTROL (const location_type& l)
+ Dhcp6Parser::make_CONFIG_CONTROL (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_CONFIG_CONTROL, l);
+ return symbol_type (token::TOKEN_CONFIG_CONTROL, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_CONFIG_DATABASES (const location_type& l)
+ Dhcp6Parser::make_CONFIG_DATABASES (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_CONFIG_DATABASES, l);
+ return symbol_type (token::TOKEN_CONFIG_DATABASES, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_INTERFACES_CONFIG (const location_type& l)
+ Dhcp6Parser::make_INTERFACES_CONFIG (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_INTERFACES_CONFIG, l);
+ return symbol_type (token::TOKEN_INTERFACES_CONFIG, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_INTERFACES (const location_type& l)
+ Dhcp6Parser::make_INTERFACES (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_INTERFACES, l);
+ return symbol_type (token::TOKEN_INTERFACES, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_RE_DETECT (const location_type& l)
+ Dhcp6Parser::make_RE_DETECT (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_RE_DETECT, l);
+ return symbol_type (token::TOKEN_RE_DETECT, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_LEASE_DATABASE (const location_type& l)
+ Dhcp6Parser::make_LEASE_DATABASE (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_LEASE_DATABASE, l);
+ return symbol_type (token::TOKEN_LEASE_DATABASE, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_HOSTS_DATABASE (const location_type& l)
+ Dhcp6Parser::make_HOSTS_DATABASE (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_HOSTS_DATABASE, l);
+ return symbol_type (token::TOKEN_HOSTS_DATABASE, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_HOSTS_DATABASES (const location_type& l)
+ Dhcp6Parser::make_HOSTS_DATABASES (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_HOSTS_DATABASES, l);
+ return symbol_type (token::TOKEN_HOSTS_DATABASES, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_TYPE (const location_type& l)
+ Dhcp6Parser::make_TYPE (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_TYPE, l);
+ return symbol_type (token::TOKEN_TYPE, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_MEMFILE (const location_type& l)
+ Dhcp6Parser::make_MEMFILE (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_MEMFILE, l);
+ return symbol_type (token::TOKEN_MEMFILE, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_MYSQL (const location_type& l)
+ Dhcp6Parser::make_MYSQL (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_MYSQL, l);
+ return symbol_type (token::TOKEN_MYSQL, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_POSTGRESQL (const location_type& l)
+ Dhcp6Parser::make_POSTGRESQL (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_POSTGRESQL, l);
+ return symbol_type (token::TOKEN_POSTGRESQL, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_CQL (const location_type& l)
+ Dhcp6Parser::make_CQL (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_CQL, l);
+ return symbol_type (token::TOKEN_CQL, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_USER (const location_type& l)
+ Dhcp6Parser::make_USER (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_USER, l);
+ return symbol_type (token::TOKEN_USER, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_PASSWORD (const location_type& l)
+ Dhcp6Parser::make_PASSWORD (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_PASSWORD, l);
+ return symbol_type (token::TOKEN_PASSWORD, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_HOST (const location_type& l)
+ Dhcp6Parser::make_HOST (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_HOST, l);
+ return symbol_type (token::TOKEN_HOST, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_PORT (const location_type& l)
+ Dhcp6Parser::make_PORT (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_PORT, l);
+ return symbol_type (token::TOKEN_PORT, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_PERSIST (const location_type& l)
+ Dhcp6Parser::make_PERSIST (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_PERSIST, l);
+ return symbol_type (token::TOKEN_PERSIST, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_LFC_INTERVAL (const location_type& l)
+ Dhcp6Parser::make_LFC_INTERVAL (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_LFC_INTERVAL, l);
+ return symbol_type (token::TOKEN_LFC_INTERVAL, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_READONLY (const location_type& l)
+ Dhcp6Parser::make_READONLY (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_READONLY, l);
+ return symbol_type (token::TOKEN_READONLY, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_CONNECT_TIMEOUT (const location_type& l)
+ Dhcp6Parser::make_CONNECT_TIMEOUT (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_CONNECT_TIMEOUT, l);
+ return symbol_type (token::TOKEN_CONNECT_TIMEOUT, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_CONTACT_POINTS (const location_type& l)
+ Dhcp6Parser::make_CONTACT_POINTS (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_CONTACT_POINTS, l);
+ return symbol_type (token::TOKEN_CONTACT_POINTS, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_MAX_RECONNECT_TRIES (const location_type& l)
+ Dhcp6Parser::make_MAX_RECONNECT_TRIES (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_MAX_RECONNECT_TRIES, l);
+ return symbol_type (token::TOKEN_MAX_RECONNECT_TRIES, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_RECONNECT_WAIT_TIME (const location_type& l)
+ Dhcp6Parser::make_RECONNECT_WAIT_TIME (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_RECONNECT_WAIT_TIME, l);
+ return symbol_type (token::TOKEN_RECONNECT_WAIT_TIME, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_KEYSPACE (const location_type& l)
+ Dhcp6Parser::make_KEYSPACE (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_KEYSPACE, l);
+ return symbol_type (token::TOKEN_KEYSPACE, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_REQUEST_TIMEOUT (const location_type& l)
+ Dhcp6Parser::make_REQUEST_TIMEOUT (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_REQUEST_TIMEOUT, l);
+ return symbol_type (token::TOKEN_REQUEST_TIMEOUT, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_TCP_KEEPALIVE (const location_type& l)
+ Dhcp6Parser::make_TCP_KEEPALIVE (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_TCP_KEEPALIVE, l);
+ return symbol_type (token::TOKEN_TCP_KEEPALIVE, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_TCP_NODELAY (const location_type& l)
+ Dhcp6Parser::make_TCP_NODELAY (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_TCP_NODELAY, l);
+ return symbol_type (token::TOKEN_TCP_NODELAY, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_PREFERRED_LIFETIME (const location_type& l)
+ Dhcp6Parser::make_PREFERRED_LIFETIME (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_PREFERRED_LIFETIME, l);
+ return symbol_type (token::TOKEN_PREFERRED_LIFETIME, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_VALID_LIFETIME (const location_type& l)
+ Dhcp6Parser::make_VALID_LIFETIME (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_VALID_LIFETIME, l);
+ return symbol_type (token::TOKEN_VALID_LIFETIME, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_RENEW_TIMER (const location_type& l)
+ Dhcp6Parser::make_RENEW_TIMER (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_RENEW_TIMER, l);
+ return symbol_type (token::TOKEN_RENEW_TIMER, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_REBIND_TIMER (const location_type& l)
+ Dhcp6Parser::make_REBIND_TIMER (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_REBIND_TIMER, l);
+ return symbol_type (token::TOKEN_REBIND_TIMER, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_DECLINE_PROBATION_PERIOD (const location_type& l)
+ Dhcp6Parser::make_DECLINE_PROBATION_PERIOD (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_DECLINE_PROBATION_PERIOD, l);
+ return symbol_type (token::TOKEN_DECLINE_PROBATION_PERIOD, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_SERVER_TAG (const location_type& l)
+ Dhcp6Parser::make_SERVER_TAG (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_SERVER_TAG, l);
+ return symbol_type (token::TOKEN_SERVER_TAG, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_SUBNET6 (const location_type& l)
+ Dhcp6Parser::make_SUBNET6 (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_SUBNET6, l);
+ return symbol_type (token::TOKEN_SUBNET6, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_OPTION_DEF (const location_type& l)
+ Dhcp6Parser::make_OPTION_DEF (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_OPTION_DEF, l);
+ return symbol_type (token::TOKEN_OPTION_DEF, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_OPTION_DATA (const location_type& l)
+ Dhcp6Parser::make_OPTION_DATA (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_OPTION_DATA, l);
+ return symbol_type (token::TOKEN_OPTION_DATA, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_NAME (const location_type& l)
+ Dhcp6Parser::make_NAME (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_NAME, l);
+ return symbol_type (token::TOKEN_NAME, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_DATA (const location_type& l)
+ Dhcp6Parser::make_DATA (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_DATA, l);
+ return symbol_type (token::TOKEN_DATA, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_CODE (const location_type& l)
+ Dhcp6Parser::make_CODE (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_CODE, l);
+ return symbol_type (token::TOKEN_CODE, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_SPACE (const location_type& l)
+ Dhcp6Parser::make_SPACE (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_SPACE, l);
+ return symbol_type (token::TOKEN_SPACE, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_CSV_FORMAT (const location_type& l)
+ Dhcp6Parser::make_CSV_FORMAT (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_CSV_FORMAT, l);
+ return symbol_type (token::TOKEN_CSV_FORMAT, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_ALWAYS_SEND (const location_type& l)
+ Dhcp6Parser::make_ALWAYS_SEND (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_ALWAYS_SEND, l);
+ return symbol_type (token::TOKEN_ALWAYS_SEND, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_RECORD_TYPES (const location_type& l)
+ Dhcp6Parser::make_RECORD_TYPES (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_RECORD_TYPES, l);
+ return symbol_type (token::TOKEN_RECORD_TYPES, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_ENCAPSULATE (const location_type& l)
+ Dhcp6Parser::make_ENCAPSULATE (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_ENCAPSULATE, l);
+ return symbol_type (token::TOKEN_ENCAPSULATE, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_ARRAY (const location_type& l)
+ Dhcp6Parser::make_ARRAY (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_ARRAY, l);
+ return symbol_type (token::TOKEN_ARRAY, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_POOLS (const location_type& l)
+ Dhcp6Parser::make_POOLS (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_POOLS, l);
+ return symbol_type (token::TOKEN_POOLS, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_POOL (const location_type& l)
+ Dhcp6Parser::make_POOL (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_POOL, l);
+ return symbol_type (token::TOKEN_POOL, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_PD_POOLS (const location_type& l)
+ Dhcp6Parser::make_PD_POOLS (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_PD_POOLS, l);
+ return symbol_type (token::TOKEN_PD_POOLS, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_PREFIX (const location_type& l)
+ Dhcp6Parser::make_PREFIX (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_PREFIX, l);
+ return symbol_type (token::TOKEN_PREFIX, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_PREFIX_LEN (const location_type& l)
+ Dhcp6Parser::make_PREFIX_LEN (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_PREFIX_LEN, l);
+ return symbol_type (token::TOKEN_PREFIX_LEN, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_EXCLUDED_PREFIX (const location_type& l)
+ Dhcp6Parser::make_EXCLUDED_PREFIX (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_EXCLUDED_PREFIX, l);
+ return symbol_type (token::TOKEN_EXCLUDED_PREFIX, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_EXCLUDED_PREFIX_LEN (const location_type& l)
+ Dhcp6Parser::make_EXCLUDED_PREFIX_LEN (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_EXCLUDED_PREFIX_LEN, l);
+ return symbol_type (token::TOKEN_EXCLUDED_PREFIX_LEN, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_DELEGATED_LEN (const location_type& l)
+ Dhcp6Parser::make_DELEGATED_LEN (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_DELEGATED_LEN, l);
+ return symbol_type (token::TOKEN_DELEGATED_LEN, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_USER_CONTEXT (const location_type& l)
+ Dhcp6Parser::make_USER_CONTEXT (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_USER_CONTEXT, l);
+ return symbol_type (token::TOKEN_USER_CONTEXT, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_COMMENT (const location_type& l)
+ Dhcp6Parser::make_COMMENT (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_COMMENT, l);
+ return symbol_type (token::TOKEN_COMMENT, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_SUBNET (const location_type& l)
+ Dhcp6Parser::make_SUBNET (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_SUBNET, l);
+ return symbol_type (token::TOKEN_SUBNET, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_INTERFACE (const location_type& l)
+ Dhcp6Parser::make_INTERFACE (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_INTERFACE, l);
+ return symbol_type (token::TOKEN_INTERFACE, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_INTERFACE_ID (const location_type& l)
+ Dhcp6Parser::make_INTERFACE_ID (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_INTERFACE_ID, l);
+ return symbol_type (token::TOKEN_INTERFACE_ID, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_ID (const location_type& l)
+ Dhcp6Parser::make_ID (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_ID, l);
+ return symbol_type (token::TOKEN_ID, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_RAPID_COMMIT (const location_type& l)
+ Dhcp6Parser::make_RAPID_COMMIT (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_RAPID_COMMIT, l);
+ return symbol_type (token::TOKEN_RAPID_COMMIT, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_RESERVATION_MODE (const location_type& l)
+ Dhcp6Parser::make_RESERVATION_MODE (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_RESERVATION_MODE, l);
+ return symbol_type (token::TOKEN_RESERVATION_MODE, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_DISABLED (const location_type& l)
+ Dhcp6Parser::make_DISABLED (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_DISABLED, l);
+ return symbol_type (token::TOKEN_DISABLED, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_OUT_OF_POOL (const location_type& l)
+ Dhcp6Parser::make_OUT_OF_POOL (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_OUT_OF_POOL, l);
+ return symbol_type (token::TOKEN_OUT_OF_POOL, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_GLOBAL (const location_type& l)
+ Dhcp6Parser::make_GLOBAL (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_GLOBAL, l);
+ return symbol_type (token::TOKEN_GLOBAL, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_ALL (const location_type& l)
+ Dhcp6Parser::make_ALL (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_ALL, l);
+ return symbol_type (token::TOKEN_ALL, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_SHARED_NETWORKS (const location_type& l)
+ Dhcp6Parser::make_SHARED_NETWORKS (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_SHARED_NETWORKS, l);
+ return symbol_type (token::TOKEN_SHARED_NETWORKS, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_MAC_SOURCES (const location_type& l)
+ Dhcp6Parser::make_MAC_SOURCES (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_MAC_SOURCES, l);
+ return symbol_type (token::TOKEN_MAC_SOURCES, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_RELAY_SUPPLIED_OPTIONS (const location_type& l)
+ Dhcp6Parser::make_RELAY_SUPPLIED_OPTIONS (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_RELAY_SUPPLIED_OPTIONS, l);
+ return symbol_type (token::TOKEN_RELAY_SUPPLIED_OPTIONS, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_HOST_RESERVATION_IDENTIFIERS (const location_type& l)
+ Dhcp6Parser::make_HOST_RESERVATION_IDENTIFIERS (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_HOST_RESERVATION_IDENTIFIERS, l);
+ return symbol_type (token::TOKEN_HOST_RESERVATION_IDENTIFIERS, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_SANITY_CHECKS (const location_type& l)
+ Dhcp6Parser::make_SANITY_CHECKS (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_SANITY_CHECKS, l);
+ return symbol_type (token::TOKEN_SANITY_CHECKS, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_LEASE_CHECKS (const location_type& l)
+ Dhcp6Parser::make_LEASE_CHECKS (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_LEASE_CHECKS, l);
+ return symbol_type (token::TOKEN_LEASE_CHECKS, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_CLIENT_CLASSES (const location_type& l)
+ Dhcp6Parser::make_CLIENT_CLASSES (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_CLIENT_CLASSES, l);
+ return symbol_type (token::TOKEN_CLIENT_CLASSES, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_REQUIRE_CLIENT_CLASSES (const location_type& l)
+ Dhcp6Parser::make_REQUIRE_CLIENT_CLASSES (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_REQUIRE_CLIENT_CLASSES, l);
+ return symbol_type (token::TOKEN_REQUIRE_CLIENT_CLASSES, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_TEST (const location_type& l)
+ Dhcp6Parser::make_TEST (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_TEST, l);
+ return symbol_type (token::TOKEN_TEST, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_ONLY_IF_REQUIRED (const location_type& l)
+ Dhcp6Parser::make_ONLY_IF_REQUIRED (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_ONLY_IF_REQUIRED, l);
+ return symbol_type (token::TOKEN_ONLY_IF_REQUIRED, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_CLIENT_CLASS (const location_type& l)
+ Dhcp6Parser::make_CLIENT_CLASS (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_CLIENT_CLASS, l);
+ return symbol_type (token::TOKEN_CLIENT_CLASS, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_RESERVATIONS (const location_type& l)
+ Dhcp6Parser::make_RESERVATIONS (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_RESERVATIONS, l);
+ return symbol_type (token::TOKEN_RESERVATIONS, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_IP_ADDRESSES (const location_type& l)
+ Dhcp6Parser::make_IP_ADDRESSES (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_IP_ADDRESSES, l);
+ return symbol_type (token::TOKEN_IP_ADDRESSES, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_PREFIXES (const location_type& l)
+ Dhcp6Parser::make_PREFIXES (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_PREFIXES, l);
+ return symbol_type (token::TOKEN_PREFIXES, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_DUID (const location_type& l)
+ Dhcp6Parser::make_DUID (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_DUID, l);
+ return symbol_type (token::TOKEN_DUID, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_HW_ADDRESS (const location_type& l)
+ Dhcp6Parser::make_HW_ADDRESS (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_HW_ADDRESS, l);
+ return symbol_type (token::TOKEN_HW_ADDRESS, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_HOSTNAME (const location_type& l)
+ Dhcp6Parser::make_HOSTNAME (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_HOSTNAME, l);
+ return symbol_type (token::TOKEN_HOSTNAME, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_FLEX_ID (const location_type& l)
+ Dhcp6Parser::make_FLEX_ID (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_FLEX_ID, l);
+ return symbol_type (token::TOKEN_FLEX_ID, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_RELAY (const location_type& l)
+ Dhcp6Parser::make_RELAY (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_RELAY, l);
+ return symbol_type (token::TOKEN_RELAY, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_IP_ADDRESS (const location_type& l)
+ Dhcp6Parser::make_IP_ADDRESS (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_IP_ADDRESS, l);
+ return symbol_type (token::TOKEN_IP_ADDRESS, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_HOOKS_LIBRARIES (const location_type& l)
+ Dhcp6Parser::make_HOOKS_LIBRARIES (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_HOOKS_LIBRARIES, l);
+ return symbol_type (token::TOKEN_HOOKS_LIBRARIES, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_LIBRARY (const location_type& l)
+ Dhcp6Parser::make_LIBRARY (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_LIBRARY, l);
+ return symbol_type (token::TOKEN_LIBRARY, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_PARAMETERS (const location_type& l)
+ Dhcp6Parser::make_PARAMETERS (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_PARAMETERS, l);
+ return symbol_type (token::TOKEN_PARAMETERS, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_EXPIRED_LEASES_PROCESSING (const location_type& l)
+ Dhcp6Parser::make_EXPIRED_LEASES_PROCESSING (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_EXPIRED_LEASES_PROCESSING, l);
+ return symbol_type (token::TOKEN_EXPIRED_LEASES_PROCESSING, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_RECLAIM_TIMER_WAIT_TIME (const location_type& l)
+ Dhcp6Parser::make_RECLAIM_TIMER_WAIT_TIME (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_RECLAIM_TIMER_WAIT_TIME, l);
+ return symbol_type (token::TOKEN_RECLAIM_TIMER_WAIT_TIME, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_FLUSH_RECLAIMED_TIMER_WAIT_TIME (const location_type& l)
+ Dhcp6Parser::make_FLUSH_RECLAIMED_TIMER_WAIT_TIME (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_FLUSH_RECLAIMED_TIMER_WAIT_TIME, l);
+ return symbol_type (token::TOKEN_FLUSH_RECLAIMED_TIMER_WAIT_TIME, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_HOLD_RECLAIMED_TIME (const location_type& l)
+ Dhcp6Parser::make_HOLD_RECLAIMED_TIME (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_HOLD_RECLAIMED_TIME, l);
+ return symbol_type (token::TOKEN_HOLD_RECLAIMED_TIME, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_MAX_RECLAIM_LEASES (const location_type& l)
+ Dhcp6Parser::make_MAX_RECLAIM_LEASES (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_MAX_RECLAIM_LEASES, l);
+ return symbol_type (token::TOKEN_MAX_RECLAIM_LEASES, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_MAX_RECLAIM_TIME (const location_type& l)
+ Dhcp6Parser::make_MAX_RECLAIM_TIME (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_MAX_RECLAIM_TIME, l);
+ return symbol_type (token::TOKEN_MAX_RECLAIM_TIME, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_UNWARNED_RECLAIM_CYCLES (const location_type& l)
+ Dhcp6Parser::make_UNWARNED_RECLAIM_CYCLES (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_UNWARNED_RECLAIM_CYCLES, l);
+ return symbol_type (token::TOKEN_UNWARNED_RECLAIM_CYCLES, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_SERVER_ID (const location_type& l)
+ Dhcp6Parser::make_SERVER_ID (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_SERVER_ID, l);
+ return symbol_type (token::TOKEN_SERVER_ID, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_LLT (const location_type& l)
+ Dhcp6Parser::make_LLT (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_LLT, l);
+ return symbol_type (token::TOKEN_LLT, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_EN (const location_type& l)
+ Dhcp6Parser::make_EN (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_EN, l);
+ return symbol_type (token::TOKEN_EN, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_LL (const location_type& l)
+ Dhcp6Parser::make_LL (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_LL, l);
+ return symbol_type (token::TOKEN_LL, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_IDENTIFIER (const location_type& l)
+ Dhcp6Parser::make_IDENTIFIER (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_IDENTIFIER, l);
+ return symbol_type (token::TOKEN_IDENTIFIER, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_HTYPE (const location_type& l)
+ Dhcp6Parser::make_HTYPE (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_HTYPE, l);
+ return symbol_type (token::TOKEN_HTYPE, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_TIME (const location_type& l)
+ Dhcp6Parser::make_TIME (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_TIME, l);
+ return symbol_type (token::TOKEN_TIME, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_ENTERPRISE_ID (const location_type& l)
+ Dhcp6Parser::make_ENTERPRISE_ID (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_ENTERPRISE_ID, l);
+ return symbol_type (token::TOKEN_ENTERPRISE_ID, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_DHCP4O6_PORT (const location_type& l)
+ Dhcp6Parser::make_DHCP4O6_PORT (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_DHCP4O6_PORT, l);
+ return symbol_type (token::TOKEN_DHCP4O6_PORT, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_CONTROL_SOCKET (const location_type& l)
+ Dhcp6Parser::make_CONTROL_SOCKET (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_CONTROL_SOCKET, l);
+ return symbol_type (token::TOKEN_CONTROL_SOCKET, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_SOCKET_TYPE (const location_type& l)
+ Dhcp6Parser::make_SOCKET_TYPE (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_SOCKET_TYPE, l);
+ return symbol_type (token::TOKEN_SOCKET_TYPE, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_SOCKET_NAME (const location_type& l)
+ Dhcp6Parser::make_SOCKET_NAME (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_SOCKET_NAME, l);
+ return symbol_type (token::TOKEN_SOCKET_NAME, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_DHCP_QUEUE_CONTROL (const location_type& l)
+ Dhcp6Parser::make_DHCP_QUEUE_CONTROL (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_DHCP_QUEUE_CONTROL, l);
+ return symbol_type (token::TOKEN_DHCP_QUEUE_CONTROL, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_DHCP_DDNS (const location_type& l)
+ Dhcp6Parser::make_DHCP_DDNS (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_DHCP_DDNS, l);
+ return symbol_type (token::TOKEN_DHCP_DDNS, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_ENABLE_UPDATES (const location_type& l)
+ Dhcp6Parser::make_ENABLE_UPDATES (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_ENABLE_UPDATES, l);
+ return symbol_type (token::TOKEN_ENABLE_UPDATES, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_QUALIFYING_SUFFIX (const location_type& l)
+ Dhcp6Parser::make_QUALIFYING_SUFFIX (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_QUALIFYING_SUFFIX, l);
+ return symbol_type (token::TOKEN_QUALIFYING_SUFFIX, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_SERVER_IP (const location_type& l)
+ Dhcp6Parser::make_SERVER_IP (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_SERVER_IP, l);
+ return symbol_type (token::TOKEN_SERVER_IP, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_SERVER_PORT (const location_type& l)
+ Dhcp6Parser::make_SERVER_PORT (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_SERVER_PORT, l);
+ return symbol_type (token::TOKEN_SERVER_PORT, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_SENDER_IP (const location_type& l)
+ Dhcp6Parser::make_SENDER_IP (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_SENDER_IP, l);
+ return symbol_type (token::TOKEN_SENDER_IP, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_SENDER_PORT (const location_type& l)
+ Dhcp6Parser::make_SENDER_PORT (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_SENDER_PORT, l);
+ return symbol_type (token::TOKEN_SENDER_PORT, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_MAX_QUEUE_SIZE (const location_type& l)
+ Dhcp6Parser::make_MAX_QUEUE_SIZE (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_MAX_QUEUE_SIZE, l);
+ return symbol_type (token::TOKEN_MAX_QUEUE_SIZE, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_NCR_PROTOCOL (const location_type& l)
+ Dhcp6Parser::make_NCR_PROTOCOL (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_NCR_PROTOCOL, l);
+ return symbol_type (token::TOKEN_NCR_PROTOCOL, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_NCR_FORMAT (const location_type& l)
+ Dhcp6Parser::make_NCR_FORMAT (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_NCR_FORMAT, l);
+ return symbol_type (token::TOKEN_NCR_FORMAT, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_ALWAYS_INCLUDE_FQDN (const location_type& l)
+ Dhcp6Parser::make_ALWAYS_INCLUDE_FQDN (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_ALWAYS_INCLUDE_FQDN, l);
+ return symbol_type (token::TOKEN_ALWAYS_INCLUDE_FQDN, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_OVERRIDE_NO_UPDATE (const location_type& l)
+ Dhcp6Parser::make_OVERRIDE_NO_UPDATE (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_OVERRIDE_NO_UPDATE, l);
+ return symbol_type (token::TOKEN_OVERRIDE_NO_UPDATE, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_OVERRIDE_CLIENT_UPDATE (const location_type& l)
+ Dhcp6Parser::make_OVERRIDE_CLIENT_UPDATE (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_OVERRIDE_CLIENT_UPDATE, l);
+ return symbol_type (token::TOKEN_OVERRIDE_CLIENT_UPDATE, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_REPLACE_CLIENT_NAME (const location_type& l)
+ Dhcp6Parser::make_REPLACE_CLIENT_NAME (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_REPLACE_CLIENT_NAME, l);
+ return symbol_type (token::TOKEN_REPLACE_CLIENT_NAME, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_GENERATED_PREFIX (const location_type& l)
+ Dhcp6Parser::make_GENERATED_PREFIX (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_GENERATED_PREFIX, l);
+ return symbol_type (token::TOKEN_GENERATED_PREFIX, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_UDP (const location_type& l)
+ Dhcp6Parser::make_UDP (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_UDP, l);
+ return symbol_type (token::TOKEN_UDP, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_TCP (const location_type& l)
+ Dhcp6Parser::make_TCP (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_TCP, l);
+ return symbol_type (token::TOKEN_TCP, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_JSON (const location_type& l)
+ Dhcp6Parser::make_JSON (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_JSON, l);
+ return symbol_type (token::TOKEN_JSON, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_WHEN_PRESENT (const location_type& l)
+ Dhcp6Parser::make_WHEN_PRESENT (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_WHEN_PRESENT, l);
+ return symbol_type (token::TOKEN_WHEN_PRESENT, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_NEVER (const location_type& l)
+ Dhcp6Parser::make_NEVER (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_NEVER, l);
+ return symbol_type (token::TOKEN_NEVER, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_ALWAYS (const location_type& l)
+ Dhcp6Parser::make_ALWAYS (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_ALWAYS, l);
+ return symbol_type (token::TOKEN_ALWAYS, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_WHEN_NOT_PRESENT (const location_type& l)
+ Dhcp6Parser::make_WHEN_NOT_PRESENT (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_WHEN_NOT_PRESENT, l);
+ return symbol_type (token::TOKEN_WHEN_NOT_PRESENT, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_HOSTNAME_CHAR_SET (const location_type& l)
+ Dhcp6Parser::make_HOSTNAME_CHAR_SET (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_HOSTNAME_CHAR_SET, l);
+ return symbol_type (token::TOKEN_HOSTNAME_CHAR_SET, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_HOSTNAME_CHAR_REPLACEMENT (const location_type& l)
+ Dhcp6Parser::make_HOSTNAME_CHAR_REPLACEMENT (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_HOSTNAME_CHAR_REPLACEMENT, l);
+ return symbol_type (token::TOKEN_HOSTNAME_CHAR_REPLACEMENT, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_LOGGING (const location_type& l)
+ Dhcp6Parser::make_LOGGING (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_LOGGING, l);
+ return symbol_type (token::TOKEN_LOGGING, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_LOGGERS (const location_type& l)
+ Dhcp6Parser::make_LOGGERS (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_LOGGERS, l);
+ return symbol_type (token::TOKEN_LOGGERS, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_OUTPUT_OPTIONS (const location_type& l)
+ Dhcp6Parser::make_OUTPUT_OPTIONS (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_OUTPUT_OPTIONS, l);
+ return symbol_type (token::TOKEN_OUTPUT_OPTIONS, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_OUTPUT (const location_type& l)
+ Dhcp6Parser::make_OUTPUT (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_OUTPUT, l);
+ return symbol_type (token::TOKEN_OUTPUT, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_DEBUGLEVEL (const location_type& l)
+ Dhcp6Parser::make_DEBUGLEVEL (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_DEBUGLEVEL, l);
+ return symbol_type (token::TOKEN_DEBUGLEVEL, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_SEVERITY (const location_type& l)
+ Dhcp6Parser::make_SEVERITY (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_SEVERITY, l);
+ return symbol_type (token::TOKEN_SEVERITY, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_FLUSH (const location_type& l)
+ Dhcp6Parser::make_FLUSH (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_FLUSH, l);
+ return symbol_type (token::TOKEN_FLUSH, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_MAXSIZE (const location_type& l)
+ Dhcp6Parser::make_MAXSIZE (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_MAXSIZE, l);
+ return symbol_type (token::TOKEN_MAXSIZE, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_MAXVER (const location_type& l)
+ Dhcp6Parser::make_MAXVER (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_MAXVER, l);
+ return symbol_type (token::TOKEN_MAXVER, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_DHCP4 (const location_type& l)
+ Dhcp6Parser::make_DHCP4 (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_DHCP4, l);
+ return symbol_type (token::TOKEN_DHCP4, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_DHCPDDNS (const location_type& l)
+ Dhcp6Parser::make_DHCPDDNS (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_DHCPDDNS, l);
+ return symbol_type (token::TOKEN_DHCPDDNS, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_CONTROL_AGENT (const location_type& l)
+ Dhcp6Parser::make_CONTROL_AGENT (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_CONTROL_AGENT, l);
+ return symbol_type (token::TOKEN_CONTROL_AGENT, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_TOPLEVEL_JSON (const location_type& l)
+ Dhcp6Parser::make_TOPLEVEL_JSON (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_TOPLEVEL_JSON, l);
+ return symbol_type (token::TOKEN_TOPLEVEL_JSON, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_TOPLEVEL_DHCP6 (const location_type& l)
+ Dhcp6Parser::make_TOPLEVEL_DHCP6 (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_TOPLEVEL_DHCP6, l);
+ return symbol_type (token::TOKEN_TOPLEVEL_DHCP6, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_SUB_DHCP6 (const location_type& l)
+ Dhcp6Parser::make_SUB_DHCP6 (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_SUB_DHCP6, l);
+ return symbol_type (token::TOKEN_SUB_DHCP6, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_SUB_INTERFACES6 (const location_type& l)
+ Dhcp6Parser::make_SUB_INTERFACES6 (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_SUB_INTERFACES6, l);
+ return symbol_type (token::TOKEN_SUB_INTERFACES6, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_SUB_SUBNET6 (const location_type& l)
+ Dhcp6Parser::make_SUB_SUBNET6 (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_SUB_SUBNET6, l);
+ return symbol_type (token::TOKEN_SUB_SUBNET6, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_SUB_POOL6 (const location_type& l)
+ Dhcp6Parser::make_SUB_POOL6 (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_SUB_POOL6, l);
+ return symbol_type (token::TOKEN_SUB_POOL6, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_SUB_PD_POOL (const location_type& l)
+ Dhcp6Parser::make_SUB_PD_POOL (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_SUB_PD_POOL, l);
+ return symbol_type (token::TOKEN_SUB_PD_POOL, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_SUB_RESERVATION (const location_type& l)
+ Dhcp6Parser::make_SUB_RESERVATION (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_SUB_RESERVATION, l);
+ return symbol_type (token::TOKEN_SUB_RESERVATION, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_SUB_OPTION_DEFS (const location_type& l)
+ Dhcp6Parser::make_SUB_OPTION_DEFS (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_SUB_OPTION_DEFS, l);
+ return symbol_type (token::TOKEN_SUB_OPTION_DEFS, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_SUB_OPTION_DEF (const location_type& l)
+ Dhcp6Parser::make_SUB_OPTION_DEF (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_SUB_OPTION_DEF, l);
+ return symbol_type (token::TOKEN_SUB_OPTION_DEF, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_SUB_OPTION_DATA (const location_type& l)
+ Dhcp6Parser::make_SUB_OPTION_DATA (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_SUB_OPTION_DATA, l);
+ return symbol_type (token::TOKEN_SUB_OPTION_DATA, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_SUB_HOOKS_LIBRARY (const location_type& l)
+ Dhcp6Parser::make_SUB_HOOKS_LIBRARY (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_SUB_HOOKS_LIBRARY, l);
+ return symbol_type (token::TOKEN_SUB_HOOKS_LIBRARY, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_SUB_DHCP_DDNS (const location_type& l)
+ Dhcp6Parser::make_SUB_DHCP_DDNS (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_SUB_DHCP_DDNS, l);
+ return symbol_type (token::TOKEN_SUB_DHCP_DDNS, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_SUB_LOGGING (const location_type& l)
+ Dhcp6Parser::make_SUB_LOGGING (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_SUB_LOGGING, l);
+ return symbol_type (token::TOKEN_SUB_LOGGING, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_SUB_CONFIG_CONTROL (const location_type& l)
+ Dhcp6Parser::make_SUB_CONFIG_CONTROL (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_SUB_CONFIG_CONTROL, l);
+ return symbol_type (token::TOKEN_SUB_CONFIG_CONTROL, YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_STRING (const std::string& v, const location_type& l)
+ Dhcp6Parser::make_STRING (YY_COPY (std::string) v, YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_STRING, v, l);
+ return symbol_type (token::TOKEN_STRING, YY_MOVE (v), YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_INTEGER (const int64_t& v, const location_type& l)
+ Dhcp6Parser::make_INTEGER (YY_COPY (int64_t) v, YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_INTEGER, v, l);
+ return symbol_type (token::TOKEN_INTEGER, YY_MOVE (v), YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_FLOAT (const double& v, const location_type& l)
+ Dhcp6Parser::make_FLOAT (YY_COPY (double) v, YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_FLOAT, v, l);
+ return symbol_type (token::TOKEN_FLOAT, YY_MOVE (v), YY_MOVE (l));
}
+ inline
Dhcp6Parser::symbol_type
- Dhcp6Parser::make_BOOLEAN (const bool& v, const location_type& l)
+ Dhcp6Parser::make_BOOLEAN (YY_COPY (bool) v, YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_BOOLEAN, v, l);
+ return symbol_type (token::TOKEN_BOOLEAN, YY_MOVE (v), YY_MOVE (l));
}
-#line 14 "dhcp6_parser.yy" // lalr1.cc:379
+#line 14 "dhcp6_parser.yy" // lalr1.cc:404
} } // isc::dhcp
-#line 2965 "dhcp6_parser.h" // lalr1.cc:379
+#line 3289 "dhcp6_parser.h" // lalr1.cc:404
-// Generated 201811151407
-// A Bison parser, made by GNU Bison 3.0.5.
+// Generated 201811172153
+// A Bison parser, made by GNU Bison 3.2.1.
// Locations for Bison parsers in C++
#ifndef YY_PARSER6_LOCATION_HH_INCLUDED
# define YY_PARSER6_LOCATION_HH_INCLUDED
-# include "position.hh"
+# include <algorithm> // std::max
+# include <iostream>
+# include <string>
-#line 14 "dhcp6_parser.yy" // location.cc:292
+# ifndef YY_NULLPTR
+# if defined __cplusplus
+# if 201103L <= __cplusplus
+# define YY_NULLPTR nullptr
+# else
+# define YY_NULLPTR 0
+# endif
+# else
+# define YY_NULLPTR ((void*)0)
+# endif
+# endif
+
+#line 14 "dhcp6_parser.yy" // location.cc:339
namespace isc { namespace dhcp {
-#line 46 "location.hh" // location.cc:292
- /// Abstract a location.
+#line 60 "location.hh" // location.cc:339
+ /// A point in a source file.
+ class position
+ {
+ public:
+ /// Construct a position.
+ explicit position (std::string* f = YY_NULLPTR,
+ unsigned l = 1u,
+ unsigned c = 1u)
+ : filename (f)
+ , line (l)
+ , column (c)
+ {}
+
+
+ /// Initialization.
+ void initialize (std::string* fn = YY_NULLPTR,
+ unsigned l = 1u,
+ unsigned c = 1u)
+ {
+ filename = fn;
+ line = l;
+ column = c;
+ }
+
+ /** \name Line and Column related manipulators
+ ** \{ */
+ /// (line related) Advance to the COUNT next lines.
+ void lines (int count = 1)
+ {
+ if (count)
+ {
+ column = 1u;
+ line = add_ (line, count, 1);
+ }
+ }
+
+ /// (column related) Advance to the COUNT next columns.
+ void columns (int count = 1)
+ {
+ column = add_ (column, count, 1);
+ }
+ /** \} */
+
+ /// File name to which this position refers.
+ std::string* filename;
+ /// Current line number.
+ unsigned line;
+ /// Current column number.
+ unsigned column;
+
+ private:
+ /// Compute max (min, lhs+rhs).
+ static unsigned add_ (unsigned lhs, int rhs, int min)
+ {
+ return static_cast<unsigned> (std::max (min,
+ static_cast<int> (lhs) + rhs));
+ }
+ };
+
+ /// Add \a width columns, in place.
+ inline position&
+ operator+= (position& res, int width)
+ {
+ res.columns (width);
+ return res;
+ }
+
+ /// Add \a width columns.
+ inline position
+ operator+ (position res, int width)
+ {
+ return res += width;
+ }
+
+ /// Subtract \a width columns, in place.
+ inline position&
+ operator-= (position& res, int width)
+ {
+ return res += -width;
+ }
+
+ /// Subtract \a width columns.
+ inline position
+ operator- (position res, int width)
+ {
+ return res -= width;
+ }
+
+ /// Compare two position objects.
+ inline bool
+ operator== (const position& pos1, const position& pos2)
+ {
+ return (pos1.line == pos2.line
+ && pos1.column == pos2.column
+ && (pos1.filename == pos2.filename
+ || (pos1.filename && pos2.filename
+ && *pos1.filename == *pos2.filename)));
+ }
+
+ /// Compare two position objects.
+ inline bool
+ operator!= (const position& pos1, const position& pos2)
+ {
+ return !(pos1 == pos2);
+ }
+
+ /** \brief Intercept output stream redirection.
+ ** \param ostr the destination output stream
+ ** \param pos a reference to the position to redirect
+ */
+ template <typename YYChar>
+ std::basic_ostream<YYChar>&
+ operator<< (std::basic_ostream<YYChar>& ostr, const position& pos)
+ {
+ if (pos.filename)
+ ostr << *pos.filename << ':';
+ return ostr << pos.line << '.' << pos.column;
+ }
+
+ /// Two points in a source file.
class location
{
public:
** Avoid duplicate information.
*/
template <typename YYChar>
- inline std::basic_ostream<YYChar>&
+ std::basic_ostream<YYChar>&
operator<< (std::basic_ostream<YYChar>& ostr, const location& loc)
{
unsigned end_col = 0 < loc.end.column ? loc.end.column - 1 : 0;
return ostr;
}
-#line 14 "dhcp6_parser.yy" // location.cc:292
+#line 14 "dhcp6_parser.yy" // location.cc:339
} } // isc::dhcp
-#line 189 "location.hh" // location.cc:292
+#line 322 "location.hh" // location.cc:339
#endif // !YY_PARSER6_LOCATION_HH_INCLUDED
-// Generated 201811151407
-// A Bison parser, made by GNU Bison 3.0.5.
-
-// Positions for Bison parsers in C++
-
-// Copyright (C) 2002-2015, 2018 Free Software Foundation, Inc.
-
-// This program is free software: you can redistribute it and/or modify
-// it under the terms of the GNU General Public License as published by
-// the Free Software Foundation, either version 3 of the License, or
-// (at your option) any later version.
-
-// This program is distributed in the hope that it will be useful,
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-// GNU General Public License for more details.
-
-// You should have received a copy of the GNU General Public License
-// along with this program. If not, see <http://www.gnu.org/licenses/>.
-
-// As a special exception, you may create a larger work that contains
-// part or all of the Bison parser skeleton and distribute that work
-// under terms of your choice, so long as that work isn't itself a
-// parser generator using the skeleton or a modified version thereof
-// as a parser skeleton. Alternatively, if you modify or redistribute
-// the parser skeleton itself, you may (at your option) remove this
-// special exception, which will cause the skeleton and the resulting
-// Bison output files to be licensed under the GNU General Public
-// License without this special exception.
-
-// This special exception was added by the Free Software Foundation in
-// version 2.2 of Bison.
-
-/**
- ** \file position.hh
- ** Define the isc::dhcp::position class.
- */
-
-#ifndef YY_PARSER6_POSITION_HH_INCLUDED
-# define YY_PARSER6_POSITION_HH_INCLUDED
-
-# include <algorithm> // std::max
-# include <iostream>
-# include <string>
-
-# ifndef YY_NULLPTR
-# if defined __cplusplus && 201103L <= __cplusplus
-# define YY_NULLPTR nullptr
-# else
-# define YY_NULLPTR 0
-# endif
-# endif
-
-#line 14 "dhcp6_parser.yy" // location.cc:292
-namespace isc { namespace dhcp {
-#line 56 "position.hh" // location.cc:292
- /// Abstract a position.
- class position
- {
- public:
- /// Construct a position.
- explicit position (std::string* f = YY_NULLPTR,
- unsigned l = 1u,
- unsigned c = 1u)
- : filename (f)
- , line (l)
- , column (c)
- {}
-
-
- /// Initialization.
- void initialize (std::string* fn = YY_NULLPTR,
- unsigned l = 1u,
- unsigned c = 1u)
- {
- filename = fn;
- line = l;
- column = c;
- }
-
- /** \name Line and Column related manipulators
- ** \{ */
- /// (line related) Advance to the COUNT next lines.
- void lines (int count = 1)
- {
- if (count)
- {
- column = 1u;
- line = add_ (line, count, 1);
- }
- }
-
- /// (column related) Advance to the COUNT next columns.
- void columns (int count = 1)
- {
- column = add_ (column, count, 1);
- }
- /** \} */
-
- /// File name to which this position refers.
- std::string* filename;
- /// Current line number.
- unsigned line;
- /// Current column number.
- unsigned column;
-
- private:
- /// Compute max(min, lhs+rhs) (provided min <= lhs).
- static unsigned add_ (unsigned lhs, int rhs, unsigned min)
- {
- return (0 < rhs || -static_cast<unsigned>(rhs) < lhs
- ? rhs + lhs
- : min);
- }
- };
-
- /// Add \a width columns, in place.
- inline position&
- operator+= (position& res, int width)
- {
- res.columns (width);
- return res;
- }
-
- /// Add \a width columns.
- inline position
- operator+ (position res, int width)
- {
- return res += width;
- }
-
- /// Subtract \a width columns, in place.
- inline position&
- operator-= (position& res, int width)
- {
- return res += -width;
- }
-
- /// Subtract \a width columns.
- inline position
- operator- (position res, int width)
- {
- return res -= width;
- }
-
- /// Compare two position objects.
- inline bool
- operator== (const position& pos1, const position& pos2)
- {
- return (pos1.line == pos2.line
- && pos1.column == pos2.column
- && (pos1.filename == pos2.filename
- || (pos1.filename && pos2.filename
- && *pos1.filename == *pos2.filename)));
- }
-
- /// Compare two position objects.
- inline bool
- operator!= (const position& pos1, const position& pos2)
- {
- return !(pos1 == pos2);
- }
-
- /** \brief Intercept output stream redirection.
- ** \param ostr the destination output stream
- ** \param pos a reference to the position to redirect
- */
- template <typename YYChar>
- inline std::basic_ostream<YYChar>&
- operator<< (std::basic_ostream<YYChar>& ostr, const position& pos)
- {
- if (pos.filename)
- ostr << *pos.filename << ':';
- return ostr << pos.line << '.' << pos.column;
- }
-
-#line 14 "dhcp6_parser.yy" // location.cc:292
-} } // isc::dhcp
-#line 179 "position.hh" // location.cc:292
-#endif // !YY_PARSER6_POSITION_HH_INCLUDED
+// Generated 201811172153
+// A Bison parser, made by GNU Bison 3.2.1.
+
+// Starting with Bison 3.2, this file is useless: the structure it
+// used to define is now defined in "location.hh".
+//
+// To get rid of this file:
+// 1. add 'require "3.2"' (or newer) to your grammar file
+// 2. remove references to this file from your build system
+// 3. if you used to include it, include "location.hh" instead.
+
+#include "location.hh"
-// Generated 201811151407
-// A Bison parser, made by GNU Bison 3.0.5.
-
-// Stack handling for Bison parsers in C++
-
-// Copyright (C) 2002-2015, 2018 Free Software Foundation, Inc.
-
-// This program is free software: you can redistribute it and/or modify
-// it under the terms of the GNU General Public License as published by
-// the Free Software Foundation, either version 3 of the License, or
-// (at your option) any later version.
-
-// This program is distributed in the hope that it will be useful,
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-// GNU General Public License for more details.
-
-// You should have received a copy of the GNU General Public License
-// along with this program. If not, see <http://www.gnu.org/licenses/>.
-
-// As a special exception, you may create a larger work that contains
-// part or all of the Bison parser skeleton and distribute that work
-// under terms of your choice, so long as that work isn't itself a
-// parser generator using the skeleton or a modified version thereof
-// as a parser skeleton. Alternatively, if you modify or redistribute
-// the parser skeleton itself, you may (at your option) remove this
-// special exception, which will cause the skeleton and the resulting
-// Bison output files to be licensed under the GNU General Public
-// License without this special exception.
-
-// This special exception was added by the Free Software Foundation in
-// version 2.2 of Bison.
-
-/**
- ** \file stack.hh
- ** Define the isc::dhcp::stack class.
- */
-
-#ifndef YY_PARSER6_STACK_HH_INCLUDED
-# define YY_PARSER6_STACK_HH_INCLUDED
-
-# include <vector>
-
-#line 14 "dhcp6_parser.yy" // stack.hh:131
-namespace isc { namespace dhcp {
-#line 46 "stack.hh" // stack.hh:131
- /// A stack with random access from its top.
- template <class T, class S = std::vector<T> >
- class stack
- {
- public:
- // Hide our reversed order.
- typedef typename S::reverse_iterator iterator;
- typedef typename S::const_reverse_iterator const_iterator;
-
- stack ()
- : seq_ ()
- {
- seq_.reserve (200);
- }
-
- stack (unsigned n)
- : seq_ (n)
- {}
-
- /// Random access.
- ///
- /// Index 0 returns the topmost element.
- T&
- operator[] (unsigned i)
- {
- return seq_[seq_.size () - 1 - i];
- }
-
- /// Random access.
- ///
- /// Index 0 returns the topmost element.
- const T&
- operator[] (unsigned i) const
- {
- return seq_[seq_.size () - 1 - i];
- }
-
- /// Steal the contents of \a t.
- ///
- /// Close to move-semantics.
- void
- push (T& t)
- {
- seq_.push_back (T());
- operator[](0).move (t);
- }
-
- void
- pop (unsigned n = 1)
- {
- for (; n; --n)
- seq_.pop_back ();
- }
-
- void
- clear ()
- {
- seq_.clear ();
- }
-
- typename S::size_type
- size () const
- {
- return seq_.size ();
- }
-
- const_iterator
- begin () const
- {
- return seq_.rbegin ();
- }
-
- const_iterator
- end () const
- {
- return seq_.rend ();
- }
-
- private:
- stack (const stack&);
- stack& operator= (const stack&);
- /// The wrapped container.
- S seq_;
- };
-
- /// Present a slice of the top of a stack.
- template <class T, class S = stack<T> >
- class slice
- {
- public:
- slice (const S& stack, unsigned range)
- : stack_ (stack)
- , range_ (range)
- {}
-
- const T&
- operator [] (unsigned i) const
- {
- return stack_[range_ - i];
- }
-
- private:
- const S& stack_;
- unsigned range_;
- };
-
-#line 14 "dhcp6_parser.yy" // stack.hh:131
-} } // isc::dhcp
-#line 155 "stack.hh" // stack.hh:131
-
-#endif // !YY_PARSER6_STACK_HH_INCLUDED
+// Generated 201811172153
+// A Bison parser, made by GNU Bison 3.2.1.
+
+// Starting with Bison 3.2, this file is useless: the structure it
+// used to define is now defined with the parser itself.
+//
+// To get rid of this file:
+// 1. add 'require "3.2"' (or newer) to your grammar file
+// 2. remove references to this file from your build system.
-// Generated 201811151407
-// A Bison parser, made by GNU Bison 3.0.5.
+// Generated 201811172153
+// A Bison parser, made by GNU Bison 3.2.1.
// Locations for Bison parsers in C++
#ifndef YY_NETCONF_LOCATION_HH_INCLUDED
# define YY_NETCONF_LOCATION_HH_INCLUDED
-# include "position.hh"
+# include <algorithm> // std::max
+# include <iostream>
+# include <string>
-#line 14 "netconf_parser.yy" // location.cc:292
+# ifndef YY_NULLPTR
+# if defined __cplusplus
+# if 201103L <= __cplusplus
+# define YY_NULLPTR nullptr
+# else
+# define YY_NULLPTR 0
+# endif
+# else
+# define YY_NULLPTR ((void*)0)
+# endif
+# endif
+
+#line 14 "netconf_parser.yy" // location.cc:339
namespace isc { namespace netconf {
-#line 46 "location.hh" // location.cc:292
- /// Abstract a location.
+#line 60 "location.hh" // location.cc:339
+ /// A point in a source file.
+ class position
+ {
+ public:
+ /// Construct a position.
+ explicit position (std::string* f = YY_NULLPTR,
+ unsigned l = 1u,
+ unsigned c = 1u)
+ : filename (f)
+ , line (l)
+ , column (c)
+ {}
+
+
+ /// Initialization.
+ void initialize (std::string* fn = YY_NULLPTR,
+ unsigned l = 1u,
+ unsigned c = 1u)
+ {
+ filename = fn;
+ line = l;
+ column = c;
+ }
+
+ /** \name Line and Column related manipulators
+ ** \{ */
+ /// (line related) Advance to the COUNT next lines.
+ void lines (int count = 1)
+ {
+ if (count)
+ {
+ column = 1u;
+ line = add_ (line, count, 1);
+ }
+ }
+
+ /// (column related) Advance to the COUNT next columns.
+ void columns (int count = 1)
+ {
+ column = add_ (column, count, 1);
+ }
+ /** \} */
+
+ /// File name to which this position refers.
+ std::string* filename;
+ /// Current line number.
+ unsigned line;
+ /// Current column number.
+ unsigned column;
+
+ private:
+ /// Compute max (min, lhs+rhs).
+ static unsigned add_ (unsigned lhs, int rhs, int min)
+ {
+ return static_cast<unsigned> (std::max (min,
+ static_cast<int> (lhs) + rhs));
+ }
+ };
+
+ /// Add \a width columns, in place.
+ inline position&
+ operator+= (position& res, int width)
+ {
+ res.columns (width);
+ return res;
+ }
+
+ /// Add \a width columns.
+ inline position
+ operator+ (position res, int width)
+ {
+ return res += width;
+ }
+
+ /// Subtract \a width columns, in place.
+ inline position&
+ operator-= (position& res, int width)
+ {
+ return res += -width;
+ }
+
+ /// Subtract \a width columns.
+ inline position
+ operator- (position res, int width)
+ {
+ return res -= width;
+ }
+
+ /// Compare two position objects.
+ inline bool
+ operator== (const position& pos1, const position& pos2)
+ {
+ return (pos1.line == pos2.line
+ && pos1.column == pos2.column
+ && (pos1.filename == pos2.filename
+ || (pos1.filename && pos2.filename
+ && *pos1.filename == *pos2.filename)));
+ }
+
+ /// Compare two position objects.
+ inline bool
+ operator!= (const position& pos1, const position& pos2)
+ {
+ return !(pos1 == pos2);
+ }
+
+ /** \brief Intercept output stream redirection.
+ ** \param ostr the destination output stream
+ ** \param pos a reference to the position to redirect
+ */
+ template <typename YYChar>
+ std::basic_ostream<YYChar>&
+ operator<< (std::basic_ostream<YYChar>& ostr, const position& pos)
+ {
+ if (pos.filename)
+ ostr << *pos.filename << ':';
+ return ostr << pos.line << '.' << pos.column;
+ }
+
+ /// Two points in a source file.
class location
{
public:
** Avoid duplicate information.
*/
template <typename YYChar>
- inline std::basic_ostream<YYChar>&
+ std::basic_ostream<YYChar>&
operator<< (std::basic_ostream<YYChar>& ostr, const location& loc)
{
unsigned end_col = 0 < loc.end.column ? loc.end.column - 1 : 0;
return ostr;
}
-#line 14 "netconf_parser.yy" // location.cc:292
+#line 14 "netconf_parser.yy" // location.cc:339
} } // isc::netconf
-#line 189 "location.hh" // location.cc:292
+#line 322 "location.hh" // location.cc:339
#endif // !YY_NETCONF_LOCATION_HH_INCLUDED
-// A Bison parser, made by GNU Bison 3.0.5.
+// A Bison parser, made by GNU Bison 3.2.1.
// Skeleton implementation for Bison LALR(1) parsers in C++
// This special exception was added by the Free Software Foundation in
// version 2.2 of Bison.
+// Undocumented macros, especially those whose name start with YY_,
+// are private implementation details. Do not rely on them.
+
+
// Take the name prefix into account.
#define yylex netconf_lex
-// First part of user declarations.
-#line 39 "netconf_parser.cc" // lalr1.cc:406
-
-# ifndef YY_NULLPTR
-# if defined __cplusplus && 201103L <= __cplusplus
-# define YY_NULLPTR nullptr
-# else
-# define YY_NULLPTR 0
-# endif
-# endif
#include "netconf_parser.h"
-// User implementation prologue.
-#line 53 "netconf_parser.cc" // lalr1.cc:414
// Unqualified %code blocks.
-#line 33 "netconf_parser.yy" // lalr1.cc:415
+#line 33 "netconf_parser.yy" // lalr1.cc:438
#include <netconf/parser_context.h>
-#line 59 "netconf_parser.cc" // lalr1.cc:415
+#line 51 "netconf_parser.cc" // lalr1.cc:438
#ifndef YY_
# endif
#endif
+// Whether we are compiled with exception support.
+#ifndef YY_EXCEPTIONS
+# if defined __GNUC__ && !defined __EXCEPTIONS
+# define YY_EXCEPTIONS 0
+# else
+# define YY_EXCEPTIONS 1
+# endif
+#endif
+
#define YYRHSLOC(Rhs, K) ((Rhs)[K].location)
/* YYLLOC_DEFAULT -- Set CURRENT to span from RHS[1] to RHS[N].
If N is 0, then set CURRENT to the empty location which ends
#define YYERROR goto yyerrorlab
#define YYRECOVERING() (!!yyerrstatus_)
-#line 14 "netconf_parser.yy" // lalr1.cc:481
+#line 14 "netconf_parser.yy" // lalr1.cc:513
namespace isc { namespace netconf {
-#line 145 "netconf_parser.cc" // lalr1.cc:481
+#line 146 "netconf_parser.cc" // lalr1.cc:513
/* Return YYSTR after stripping away unnecessary quotes and
backslashes, so that it's suitable for yyerror. The heuristic is
NetconfParser::stack_symbol_type::stack_symbol_type ()
{}
- NetconfParser::stack_symbol_type::stack_symbol_type (const stack_symbol_type& that)
- : super_type (that.state, that.location)
+ NetconfParser::stack_symbol_type::stack_symbol_type (YY_RVREF (stack_symbol_type) that)
+ : super_type (YY_MOVE (that.state), YY_MOVE (that.location))
{
switch (that.type_get ())
{
case 57: // value
case 60: // map_value
case 119: // socket_type_value
- value.copy< ElementPtr > (that.value);
+ value.YY_MOVE_OR_COPY< ElementPtr > (YY_MOVE (that.value));
break;
case 48: // "boolean"
- value.copy< bool > (that.value);
+ value.YY_MOVE_OR_COPY< bool > (YY_MOVE (that.value));
break;
case 47: // "floating point"
- value.copy< double > (that.value);
+ value.YY_MOVE_OR_COPY< double > (YY_MOVE (that.value));
break;
case 46: // "integer"
- value.copy< int64_t > (that.value);
+ value.YY_MOVE_OR_COPY< int64_t > (YY_MOVE (that.value));
break;
case 45: // "constant string"
- value.copy< std::string > (that.value);
+ value.YY_MOVE_OR_COPY< std::string > (YY_MOVE (that.value));
break;
default:
break;
}
+#if defined __cplusplus && 201103L <= __cplusplus
+ // that is emptied.
+ that.state = empty_state;
+#endif
}
- NetconfParser::stack_symbol_type::stack_symbol_type (state_type s, symbol_type& that)
- : super_type (s, that.location)
+ NetconfParser::stack_symbol_type::stack_symbol_type (state_type s, YY_MOVE_REF (symbol_type) that)
+ : super_type (s, YY_MOVE (that.location))
{
switch (that.type_get ())
{
case 57: // value
case 60: // map_value
case 119: // socket_type_value
- value.move< ElementPtr > (that.value);
+ value.move< ElementPtr > (YY_MOVE (that.value));
break;
case 48: // "boolean"
- value.move< bool > (that.value);
+ value.move< bool > (YY_MOVE (that.value));
break;
case 47: // "floating point"
- value.move< double > (that.value);
+ value.move< double > (YY_MOVE (that.value));
break;
case 46: // "integer"
- value.move< int64_t > (that.value);
+ value.move< int64_t > (YY_MOVE (that.value));
break;
case 45: // "constant string"
- value.move< std::string > (that.value);
+ value.move< std::string > (YY_MOVE (that.value));
break;
default:
that.type = empty_symbol;
}
+#if !defined __cplusplus || __cplusplus < 201103L
NetconfParser::stack_symbol_type&
- NetconfParser::stack_symbol_type::operator= (const stack_symbol_type& that)
+ NetconfParser::stack_symbol_type::operator= (stack_symbol_type& that)
{
state = that.state;
switch (that.type_get ())
case 57: // value
case 60: // map_value
case 119: // socket_type_value
- value.copy< ElementPtr > (that.value);
+ value.move< ElementPtr > (that.value);
break;
case 48: // "boolean"
- value.copy< bool > (that.value);
+ value.move< bool > (that.value);
break;
case 47: // "floating point"
- value.copy< double > (that.value);
+ value.move< double > (that.value);
break;
case 46: // "integer"
- value.copy< int64_t > (that.value);
+ value.move< int64_t > (that.value);
break;
case 45: // "constant string"
- value.copy< std::string > (that.value);
+ value.move< std::string > (that.value);
break;
default:
}
location = that.location;
+ // that is emptied.
+ that.state = empty_state;
return *this;
}
-
+#endif
template <typename Base>
void
{
case 45: // "constant string"
-#line 107 "netconf_parser.yy" // lalr1.cc:635
+#line 107 "netconf_parser.yy" // lalr1.cc:672
{ yyoutput << yysym.value.template as< std::string > (); }
-#line 378 "netconf_parser.cc" // lalr1.cc:635
+#line 386 "netconf_parser.cc" // lalr1.cc:672
break;
case 46: // "integer"
-#line 107 "netconf_parser.yy" // lalr1.cc:635
+#line 107 "netconf_parser.yy" // lalr1.cc:672
{ yyoutput << yysym.value.template as< int64_t > (); }
-#line 385 "netconf_parser.cc" // lalr1.cc:635
+#line 393 "netconf_parser.cc" // lalr1.cc:672
break;
case 47: // "floating point"
-#line 107 "netconf_parser.yy" // lalr1.cc:635
+#line 107 "netconf_parser.yy" // lalr1.cc:672
{ yyoutput << yysym.value.template as< double > (); }
-#line 392 "netconf_parser.cc" // lalr1.cc:635
+#line 400 "netconf_parser.cc" // lalr1.cc:672
break;
case 48: // "boolean"
-#line 107 "netconf_parser.yy" // lalr1.cc:635
+#line 107 "netconf_parser.yy" // lalr1.cc:672
{ yyoutput << yysym.value.template as< bool > (); }
-#line 399 "netconf_parser.cc" // lalr1.cc:635
+#line 407 "netconf_parser.cc" // lalr1.cc:672
break;
case 57: // value
-#line 107 "netconf_parser.yy" // lalr1.cc:635
+#line 107 "netconf_parser.yy" // lalr1.cc:672
{ yyoutput << yysym.value.template as< ElementPtr > (); }
-#line 406 "netconf_parser.cc" // lalr1.cc:635
+#line 414 "netconf_parser.cc" // lalr1.cc:672
break;
case 60: // map_value
-#line 107 "netconf_parser.yy" // lalr1.cc:635
+#line 107 "netconf_parser.yy" // lalr1.cc:672
{ yyoutput << yysym.value.template as< ElementPtr > (); }
-#line 413 "netconf_parser.cc" // lalr1.cc:635
+#line 421 "netconf_parser.cc" // lalr1.cc:672
break;
case 119: // socket_type_value
-#line 107 "netconf_parser.yy" // lalr1.cc:635
+#line 107 "netconf_parser.yy" // lalr1.cc:672
{ yyoutput << yysym.value.template as< ElementPtr > (); }
-#line 420 "netconf_parser.cc" // lalr1.cc:635
+#line 428 "netconf_parser.cc" // lalr1.cc:672
break;
#endif
void
- NetconfParser::yypush_ (const char* m, state_type s, symbol_type& sym)
+ NetconfParser::yypush_ (const char* m, YY_MOVE_REF (stack_symbol_type) sym)
{
- stack_symbol_type t (s, sym);
- yypush_ (m, t);
+ if (m)
+ YY_SYMBOL_PRINT (m, sym);
+ yystack_.push (YY_MOVE (sym));
}
void
- NetconfParser::yypush_ (const char* m, stack_symbol_type& s)
+ NetconfParser::yypush_ (const char* m, state_type s, YY_MOVE_REF (symbol_type) sym)
{
- if (m)
- YY_SYMBOL_PRINT (m, s);
- yystack_.push (s);
+#if defined __cplusplus && 201103L <= __cplusplus
+ yypush_ (m, stack_symbol_type (s, std::move (sym)));
+#else
+ stack_symbol_type ss (s, sym);
+ yypush_ (m, ss);
+#endif
}
void
- NetconfParser::yypop_ (unsigned n)
+ NetconfParser::yypop_ (int n)
{
yystack_.pop (n);
}
return yyvalue == yytable_ninf_;
}
+ int
+ NetconfParser::operator() ()
+ {
+ return parse ();
+ }
+
int
NetconfParser::parse ()
{
/// The return value of parse ().
int yyresult;
- // FIXME: This shoud be completely indented. It is not yet to
- // avoid gratuitous conflicts when merging into the master branch.
+#if YY_EXCEPTIONS
try
+#endif // YY_EXCEPTIONS
{
YYCDEBUG << "Starting parse\n";
location values to have been already stored, initialize these
stacks with a primary value. */
yystack_.clear ();
- yypush_ (YY_NULLPTR, 0, yyla);
+ yypush_ (YY_NULLPTR, 0, YY_MOVE (yyla));
// A new symbol was pushed on the stack.
yynewstate:
// Backup.
yybackup:
-
// Try to take a decision without lookahead.
yyn = yypact_[yystack_[0].state];
if (yy_pact_value_is_default_ (yyn))
if (yyla.empty ())
{
YYCDEBUG << "Reading a token: ";
+#if YY_EXCEPTIONS
try
+#endif // YY_EXCEPTIONS
{
symbol_type yylookahead (yylex (ctx));
yyla.move (yylookahead);
}
+#if YY_EXCEPTIONS
catch (const syntax_error& yyexc)
{
error (yyexc);
goto yyerrlab1;
}
+#endif // YY_EXCEPTIONS
}
YY_SYMBOL_PRINT ("Next token is", yyla);
--yyerrstatus_;
// Shift the lookahead token.
- yypush_ ("Shifting", yyn, yyla);
+ yypush_ ("Shifting", yyn, YY_MOVE (yyla));
goto yynewstate;
/*-----------------------------------------------------------.
case 57: // value
case 60: // map_value
case 119: // socket_type_value
- yylhs.value.build< ElementPtr > ();
+ yylhs.value.emplace< ElementPtr > ();
break;
case 48: // "boolean"
- yylhs.value.build< bool > ();
+ yylhs.value.emplace< bool > ();
break;
case 47: // "floating point"
- yylhs.value.build< double > ();
+ yylhs.value.emplace< double > ();
break;
case 46: // "integer"
- yylhs.value.build< int64_t > ();
+ yylhs.value.emplace< int64_t > ();
break;
case 45: // "constant string"
- yylhs.value.build< std::string > ();
+ yylhs.value.emplace< std::string > ();
break;
default:
// Perform the reduction.
YY_REDUCE_PRINT (yyn);
+#if YY_EXCEPTIONS
try
+#endif // YY_EXCEPTIONS
{
switch (yyn)
{
case 2:
-#line 118 "netconf_parser.yy" // lalr1.cc:856
+#line 118 "netconf_parser.yy" // lalr1.cc:907
{ ctx.ctx_ = ctx.NO_KEYWORDS; }
-#line 660 "netconf_parser.cc" // lalr1.cc:856
+#line 683 "netconf_parser.cc" // lalr1.cc:907
break;
case 4:
-#line 119 "netconf_parser.yy" // lalr1.cc:856
+#line 119 "netconf_parser.yy" // lalr1.cc:907
{ ctx.ctx_ = ctx.CONFIG; }
-#line 666 "netconf_parser.cc" // lalr1.cc:856
+#line 689 "netconf_parser.cc" // lalr1.cc:907
break;
case 6:
-#line 120 "netconf_parser.yy" // lalr1.cc:856
+#line 120 "netconf_parser.yy" // lalr1.cc:907
{ ctx.ctx_ = ctx.NETCONF; }
-#line 672 "netconf_parser.cc" // lalr1.cc:856
+#line 695 "netconf_parser.cc" // lalr1.cc:907
break;
case 8:
-#line 128 "netconf_parser.yy" // lalr1.cc:856
+#line 128 "netconf_parser.yy" // lalr1.cc:907
{
// Parse the Netconf map
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.push_back(m);
}
-#line 682 "netconf_parser.cc" // lalr1.cc:856
+#line 705 "netconf_parser.cc" // lalr1.cc:907
break;
case 9:
-#line 132 "netconf_parser.yy" // lalr1.cc:856
+#line 132 "netconf_parser.yy" // lalr1.cc:907
{
// parsing completed
}
-#line 690 "netconf_parser.cc" // lalr1.cc:856
+#line 713 "netconf_parser.cc" // lalr1.cc:907
break;
case 10:
-#line 139 "netconf_parser.yy" // lalr1.cc:856
+#line 139 "netconf_parser.yy" // lalr1.cc:907
{
// Push back the JSON value on the stack
ctx.stack_.push_back(yystack_[0].value.as< ElementPtr > ());
}
-#line 699 "netconf_parser.cc" // lalr1.cc:856
+#line 722 "netconf_parser.cc" // lalr1.cc:907
break;
case 11:
-#line 145 "netconf_parser.yy" // lalr1.cc:856
+#line 145 "netconf_parser.yy" // lalr1.cc:907
{ yylhs.value.as< ElementPtr > () = ElementPtr(new IntElement(yystack_[0].value.as< int64_t > (), ctx.loc2pos(yystack_[0].location))); }
-#line 705 "netconf_parser.cc" // lalr1.cc:856
+#line 728 "netconf_parser.cc" // lalr1.cc:907
break;
case 12:
-#line 146 "netconf_parser.yy" // lalr1.cc:856
+#line 146 "netconf_parser.yy" // lalr1.cc:907
{ yylhs.value.as< ElementPtr > () = ElementPtr(new DoubleElement(yystack_[0].value.as< double > (), ctx.loc2pos(yystack_[0].location))); }
-#line 711 "netconf_parser.cc" // lalr1.cc:856
+#line 734 "netconf_parser.cc" // lalr1.cc:907
break;
case 13:
-#line 147 "netconf_parser.yy" // lalr1.cc:856
+#line 147 "netconf_parser.yy" // lalr1.cc:907
{ yylhs.value.as< ElementPtr > () = ElementPtr(new BoolElement(yystack_[0].value.as< bool > (), ctx.loc2pos(yystack_[0].location))); }
-#line 717 "netconf_parser.cc" // lalr1.cc:856
+#line 740 "netconf_parser.cc" // lalr1.cc:907
break;
case 14:
-#line 148 "netconf_parser.yy" // lalr1.cc:856
+#line 148 "netconf_parser.yy" // lalr1.cc:907
{ yylhs.value.as< ElementPtr > () = ElementPtr(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location))); }
-#line 723 "netconf_parser.cc" // lalr1.cc:856
+#line 746 "netconf_parser.cc" // lalr1.cc:907
break;
case 15:
-#line 149 "netconf_parser.yy" // lalr1.cc:856
+#line 149 "netconf_parser.yy" // lalr1.cc:907
{ yylhs.value.as< ElementPtr > () = ElementPtr(new NullElement(ctx.loc2pos(yystack_[0].location))); }
-#line 729 "netconf_parser.cc" // lalr1.cc:856
+#line 752 "netconf_parser.cc" // lalr1.cc:907
break;
case 16:
-#line 150 "netconf_parser.yy" // lalr1.cc:856
+#line 150 "netconf_parser.yy" // lalr1.cc:907
{ yylhs.value.as< ElementPtr > () = ctx.stack_.back(); ctx.stack_.pop_back(); }
-#line 735 "netconf_parser.cc" // lalr1.cc:856
+#line 758 "netconf_parser.cc" // lalr1.cc:907
break;
case 17:
-#line 151 "netconf_parser.yy" // lalr1.cc:856
+#line 151 "netconf_parser.yy" // lalr1.cc:907
{ yylhs.value.as< ElementPtr > () = ctx.stack_.back(); ctx.stack_.pop_back(); }
-#line 741 "netconf_parser.cc" // lalr1.cc:856
+#line 764 "netconf_parser.cc" // lalr1.cc:907
break;
case 18:
-#line 155 "netconf_parser.yy" // lalr1.cc:856
+#line 155 "netconf_parser.yy" // lalr1.cc:907
{
// This code is executed when we're about to start parsing
// the content of the map
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.push_back(m);
}
-#line 752 "netconf_parser.cc" // lalr1.cc:856
+#line 775 "netconf_parser.cc" // lalr1.cc:907
break;
case 19:
-#line 160 "netconf_parser.yy" // lalr1.cc:856
+#line 160 "netconf_parser.yy" // lalr1.cc:907
{
// map parsing completed. If we ever want to do any wrap up
// (maybe some sanity checking), this would be the best place
// for it.
}
-#line 762 "netconf_parser.cc" // lalr1.cc:856
+#line 785 "netconf_parser.cc" // lalr1.cc:907
break;
case 20:
-#line 166 "netconf_parser.yy" // lalr1.cc:856
+#line 166 "netconf_parser.yy" // lalr1.cc:907
{ yylhs.value.as< ElementPtr > () = ctx.stack_.back(); ctx.stack_.pop_back(); }
-#line 768 "netconf_parser.cc" // lalr1.cc:856
+#line 791 "netconf_parser.cc" // lalr1.cc:907
break;
case 23:
-#line 180 "netconf_parser.yy" // lalr1.cc:856
+#line 180 "netconf_parser.yy" // lalr1.cc:907
{
// map containing a single entry
ctx.stack_.back()->set(yystack_[2].value.as< std::string > (), yystack_[0].value.as< ElementPtr > ());
}
-#line 777 "netconf_parser.cc" // lalr1.cc:856
+#line 800 "netconf_parser.cc" // lalr1.cc:907
break;
case 24:
-#line 184 "netconf_parser.yy" // lalr1.cc:856
+#line 184 "netconf_parser.yy" // lalr1.cc:907
{
// map consisting of a shorter map followed by
// comma and string:value
ctx.stack_.back()->set(yystack_[2].value.as< std::string > (), yystack_[0].value.as< ElementPtr > ());
}
-#line 787 "netconf_parser.cc" // lalr1.cc:856
+#line 810 "netconf_parser.cc" // lalr1.cc:907
break;
case 25:
-#line 191 "netconf_parser.yy" // lalr1.cc:856
+#line 191 "netconf_parser.yy" // lalr1.cc:907
{
ElementPtr l(new ListElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.push_back(l);
}
-#line 796 "netconf_parser.cc" // lalr1.cc:856
+#line 819 "netconf_parser.cc" // lalr1.cc:907
break;
case 26:
-#line 194 "netconf_parser.yy" // lalr1.cc:856
+#line 194 "netconf_parser.yy" // lalr1.cc:907
{
}
-#line 803 "netconf_parser.cc" // lalr1.cc:856
+#line 826 "netconf_parser.cc" // lalr1.cc:907
break;
case 29:
-#line 201 "netconf_parser.yy" // lalr1.cc:856
+#line 201 "netconf_parser.yy" // lalr1.cc:907
{
// List consisting of a single element.
ctx.stack_.back()->add(yystack_[0].value.as< ElementPtr > ());
}
-#line 812 "netconf_parser.cc" // lalr1.cc:856
+#line 835 "netconf_parser.cc" // lalr1.cc:907
break;
case 30:
-#line 205 "netconf_parser.yy" // lalr1.cc:856
+#line 205 "netconf_parser.yy" // lalr1.cc:907
{
// List ending with , and a value.
ctx.stack_.back()->add(yystack_[0].value.as< ElementPtr > ());
}
-#line 821 "netconf_parser.cc" // lalr1.cc:856
+#line 844 "netconf_parser.cc" // lalr1.cc:907
break;
case 31:
-#line 218 "netconf_parser.yy" // lalr1.cc:856
+#line 218 "netconf_parser.yy" // lalr1.cc:907
{
const std::string& where = ctx.contextName();
const std::string& keyword = yystack_[1].value.as< std::string > ();
error(yystack_[1].location,
"got unexpected keyword \"" + keyword + "\" in " + where + " map.");
}
-#line 832 "netconf_parser.cc" // lalr1.cc:856
+#line 855 "netconf_parser.cc" // lalr1.cc:907
break;
case 32:
-#line 226 "netconf_parser.yy" // lalr1.cc:856
+#line 226 "netconf_parser.yy" // lalr1.cc:907
{
// This code is executed when we're about to start parsing
// the content of the map
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.push_back(m);
}
-#line 843 "netconf_parser.cc" // lalr1.cc:856
+#line 866 "netconf_parser.cc" // lalr1.cc:907
break;
case 33:
-#line 231 "netconf_parser.yy" // lalr1.cc:856
+#line 231 "netconf_parser.yy" // lalr1.cc:907
{
// map parsing completed. If we ever want to do any wrap up
// (maybe some sanity checking), this would be the best place
// for it.
}
-#line 853 "netconf_parser.cc" // lalr1.cc:856
+#line 876 "netconf_parser.cc" // lalr1.cc:907
break;
case 38:
-#line 248 "netconf_parser.yy" // lalr1.cc:856
+#line 248 "netconf_parser.yy" // lalr1.cc:907
{
// Let's create a MapElement that will represent it, add it to the
ctx.stack_.push_back(m);
ctx.enter(ctx.NETCONF);
}
-#line 869 "netconf_parser.cc" // lalr1.cc:856
+#line 892 "netconf_parser.cc" // lalr1.cc:907
break;
case 39:
-#line 258 "netconf_parser.yy" // lalr1.cc:856
+#line 258 "netconf_parser.yy" // lalr1.cc:907
{
// Ok, we're done with parsing Netconf. Let's take the map
// off the stack.
ctx.stack_.pop_back();
ctx.leave();
}
-#line 880 "netconf_parser.cc" // lalr1.cc:856
+#line 903 "netconf_parser.cc" // lalr1.cc:907
break;
case 52:
-#line 285 "netconf_parser.yy" // lalr1.cc:856
+#line 285 "netconf_parser.yy" // lalr1.cc:907
{
ElementPtr flag(new BoolElement(yystack_[0].value.as< bool > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("boot-update", flag);
}
-#line 889 "netconf_parser.cc" // lalr1.cc:856
+#line 912 "netconf_parser.cc" // lalr1.cc:907
break;
case 53:
-#line 290 "netconf_parser.yy" // lalr1.cc:856
+#line 290 "netconf_parser.yy" // lalr1.cc:907
{
ElementPtr flag(new BoolElement(yystack_[0].value.as< bool > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("subscribe-changes", flag);
}
-#line 898 "netconf_parser.cc" // lalr1.cc:856
+#line 921 "netconf_parser.cc" // lalr1.cc:907
break;
case 54:
-#line 295 "netconf_parser.yy" // lalr1.cc:856
+#line 295 "netconf_parser.yy" // lalr1.cc:907
{
ElementPtr flag(new BoolElement(yystack_[0].value.as< bool > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("validate-changes", flag);
}
-#line 907 "netconf_parser.cc" // lalr1.cc:856
+#line 930 "netconf_parser.cc" // lalr1.cc:907
break;
case 55:
-#line 300 "netconf_parser.yy" // lalr1.cc:856
+#line 300 "netconf_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORDS);
}
-#line 915 "netconf_parser.cc" // lalr1.cc:856
+#line 938 "netconf_parser.cc" // lalr1.cc:907
break;
case 56:
-#line 302 "netconf_parser.yy" // lalr1.cc:856
+#line 302 "netconf_parser.yy" // lalr1.cc:907
{
ElementPtr parent = ctx.stack_.back();
ElementPtr user_context = yystack_[0].value.as< ElementPtr > ();
parent->set("user-context", user_context);
ctx.leave();
}
-#line 942 "netconf_parser.cc" // lalr1.cc:856
+#line 965 "netconf_parser.cc" // lalr1.cc:907
break;
case 57:
-#line 325 "netconf_parser.yy" // lalr1.cc:856
+#line 325 "netconf_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORDS);
}
-#line 950 "netconf_parser.cc" // lalr1.cc:856
+#line 973 "netconf_parser.cc" // lalr1.cc:907
break;
case 58:
-#line 327 "netconf_parser.yy" // lalr1.cc:856
+#line 327 "netconf_parser.yy" // lalr1.cc:907
{
ElementPtr parent = ctx.stack_.back();
ElementPtr user_context(new MapElement(ctx.loc2pos(yystack_[3].location)));
parent->set("user-context", user_context);
ctx.leave();
}
-#line 979 "netconf_parser.cc" // lalr1.cc:856
+#line 1002 "netconf_parser.cc" // lalr1.cc:907
break;
case 59:
-#line 353 "netconf_parser.yy" // lalr1.cc:856
+#line 353 "netconf_parser.yy" // lalr1.cc:907
{
ElementPtr l(new ListElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("hooks-libraries", l);
ctx.stack_.push_back(l);
ctx.enter(ctx.HOOKS_LIBRARIES);
}
-#line 990 "netconf_parser.cc" // lalr1.cc:856
+#line 1013 "netconf_parser.cc" // lalr1.cc:907
break;
case 60:
-#line 358 "netconf_parser.yy" // lalr1.cc:856
+#line 358 "netconf_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
ctx.leave();
}
-#line 999 "netconf_parser.cc" // lalr1.cc:856
+#line 1022 "netconf_parser.cc" // lalr1.cc:907
break;
case 65:
-#line 371 "netconf_parser.yy" // lalr1.cc:856
+#line 371 "netconf_parser.yy" // lalr1.cc:907
{
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->add(m);
ctx.stack_.push_back(m);
}
-#line 1009 "netconf_parser.cc" // lalr1.cc:856
+#line 1032 "netconf_parser.cc" // lalr1.cc:907
break;
case 66:
-#line 375 "netconf_parser.yy" // lalr1.cc:856
+#line 375 "netconf_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
}
-#line 1017 "netconf_parser.cc" // lalr1.cc:856
+#line 1040 "netconf_parser.cc" // lalr1.cc:907
break;
case 72:
-#line 388 "netconf_parser.yy" // lalr1.cc:856
+#line 388 "netconf_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORDS);
}
-#line 1025 "netconf_parser.cc" // lalr1.cc:856
+#line 1048 "netconf_parser.cc" // lalr1.cc:907
break;
case 73:
-#line 390 "netconf_parser.yy" // lalr1.cc:856
+#line 390 "netconf_parser.yy" // lalr1.cc:907
{
ElementPtr lib(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("library", lib);
ctx.leave();
}
-#line 1035 "netconf_parser.cc" // lalr1.cc:856
+#line 1058 "netconf_parser.cc" // lalr1.cc:907
break;
case 74:
-#line 396 "netconf_parser.yy" // lalr1.cc:856
+#line 396 "netconf_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORDS);
}
-#line 1043 "netconf_parser.cc" // lalr1.cc:856
+#line 1066 "netconf_parser.cc" // lalr1.cc:907
break;
case 75:
-#line 398 "netconf_parser.yy" // lalr1.cc:856
+#line 398 "netconf_parser.yy" // lalr1.cc:907
{
ctx.stack_.back()->set("parameters", yystack_[0].value.as< ElementPtr > ());
ctx.leave();
}
-#line 1052 "netconf_parser.cc" // lalr1.cc:856
+#line 1075 "netconf_parser.cc" // lalr1.cc:907
break;
case 76:
-#line 406 "netconf_parser.yy" // lalr1.cc:856
+#line 406 "netconf_parser.yy" // lalr1.cc:907
{
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[2].location)));
ctx.stack_.back()->set("managed-servers", m);
ctx.stack_.push_back(m);
ctx.enter(ctx.MANAGED_SERVERS);
}
-#line 1063 "netconf_parser.cc" // lalr1.cc:856
+#line 1086 "netconf_parser.cc" // lalr1.cc:907
break;
case 77:
-#line 411 "netconf_parser.yy" // lalr1.cc:856
+#line 411 "netconf_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
ctx.leave();
}
-#line 1072 "netconf_parser.cc" // lalr1.cc:856
+#line 1095 "netconf_parser.cc" // lalr1.cc:907
break;
case 87:
-#line 435 "netconf_parser.yy" // lalr1.cc:856
+#line 435 "netconf_parser.yy" // lalr1.cc:907
{
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("dhcp4", m);
ctx.stack_.push_back(m);
ctx.enter(ctx.SERVER);
}
-#line 1083 "netconf_parser.cc" // lalr1.cc:856
+#line 1106 "netconf_parser.cc" // lalr1.cc:907
break;
case 88:
-#line 440 "netconf_parser.yy" // lalr1.cc:856
+#line 440 "netconf_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
ctx.leave();
}
-#line 1092 "netconf_parser.cc" // lalr1.cc:856
+#line 1115 "netconf_parser.cc" // lalr1.cc:907
break;
case 89:
-#line 446 "netconf_parser.yy" // lalr1.cc:856
+#line 446 "netconf_parser.yy" // lalr1.cc:907
{
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("dhcp6", m);
ctx.stack_.push_back(m);
ctx.enter(ctx.SERVER);
}
-#line 1103 "netconf_parser.cc" // lalr1.cc:856
+#line 1126 "netconf_parser.cc" // lalr1.cc:907
break;
case 90:
-#line 451 "netconf_parser.yy" // lalr1.cc:856
+#line 451 "netconf_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
ctx.leave();
}
-#line 1112 "netconf_parser.cc" // lalr1.cc:856
+#line 1135 "netconf_parser.cc" // lalr1.cc:907
break;
case 91:
-#line 457 "netconf_parser.yy" // lalr1.cc:856
+#line 457 "netconf_parser.yy" // lalr1.cc:907
{
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("d2", m);
ctx.stack_.push_back(m);
ctx.enter(ctx.SERVER);
}
-#line 1123 "netconf_parser.cc" // lalr1.cc:856
+#line 1146 "netconf_parser.cc" // lalr1.cc:907
break;
case 92:
-#line 462 "netconf_parser.yy" // lalr1.cc:856
+#line 462 "netconf_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
ctx.leave();
}
-#line 1132 "netconf_parser.cc" // lalr1.cc:856
+#line 1155 "netconf_parser.cc" // lalr1.cc:907
break;
case 93:
-#line 468 "netconf_parser.yy" // lalr1.cc:856
+#line 468 "netconf_parser.yy" // lalr1.cc:907
{
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("ca", m);
ctx.stack_.push_back(m);
ctx.enter(ctx.SERVER);
}
-#line 1143 "netconf_parser.cc" // lalr1.cc:856
+#line 1166 "netconf_parser.cc" // lalr1.cc:907
break;
case 94:
-#line 473 "netconf_parser.yy" // lalr1.cc:856
+#line 473 "netconf_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
ctx.leave();
}
-#line 1152 "netconf_parser.cc" // lalr1.cc:856
+#line 1175 "netconf_parser.cc" // lalr1.cc:907
break;
case 105:
-#line 495 "netconf_parser.yy" // lalr1.cc:856
+#line 495 "netconf_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORDS);
}
-#line 1160 "netconf_parser.cc" // lalr1.cc:856
+#line 1183 "netconf_parser.cc" // lalr1.cc:907
break;
case 106:
-#line 497 "netconf_parser.yy" // lalr1.cc:856
+#line 497 "netconf_parser.yy" // lalr1.cc:907
{
ElementPtr model(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("model", model);
ctx.leave();
}
-#line 1170 "netconf_parser.cc" // lalr1.cc:856
+#line 1193 "netconf_parser.cc" // lalr1.cc:907
break;
case 107:
-#line 504 "netconf_parser.yy" // lalr1.cc:856
+#line 504 "netconf_parser.yy" // lalr1.cc:907
{
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("control-socket", m);
ctx.stack_.push_back(m);
ctx.enter(ctx.CONTROL_SOCKET);
}
-#line 1181 "netconf_parser.cc" // lalr1.cc:856
+#line 1204 "netconf_parser.cc" // lalr1.cc:907
break;
case 108:
-#line 509 "netconf_parser.yy" // lalr1.cc:856
+#line 509 "netconf_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
ctx.leave();
}
-#line 1190 "netconf_parser.cc" // lalr1.cc:856
+#line 1213 "netconf_parser.cc" // lalr1.cc:907
break;
case 117:
-#line 527 "netconf_parser.yy" // lalr1.cc:856
+#line 527 "netconf_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.SOCKET_TYPE);
}
-#line 1198 "netconf_parser.cc" // lalr1.cc:856
+#line 1221 "netconf_parser.cc" // lalr1.cc:907
break;
case 118:
-#line 529 "netconf_parser.yy" // lalr1.cc:856
+#line 529 "netconf_parser.yy" // lalr1.cc:907
{
ctx.stack_.back()->set("socket-type", yystack_[0].value.as< ElementPtr > ());
ctx.leave();
}
-#line 1207 "netconf_parser.cc" // lalr1.cc:856
+#line 1230 "netconf_parser.cc" // lalr1.cc:907
break;
case 119:
-#line 535 "netconf_parser.yy" // lalr1.cc:856
+#line 535 "netconf_parser.yy" // lalr1.cc:907
{ yylhs.value.as< ElementPtr > () = ElementPtr(new StringElement("unix", ctx.loc2pos(yystack_[0].location))); }
-#line 1213 "netconf_parser.cc" // lalr1.cc:856
+#line 1236 "netconf_parser.cc" // lalr1.cc:907
break;
case 120:
-#line 536 "netconf_parser.yy" // lalr1.cc:856
+#line 536 "netconf_parser.yy" // lalr1.cc:907
{ yylhs.value.as< ElementPtr > () = ElementPtr(new StringElement("http", ctx.loc2pos(yystack_[0].location))); }
-#line 1219 "netconf_parser.cc" // lalr1.cc:856
+#line 1242 "netconf_parser.cc" // lalr1.cc:907
break;
case 121:
-#line 537 "netconf_parser.yy" // lalr1.cc:856
+#line 537 "netconf_parser.yy" // lalr1.cc:907
{ yylhs.value.as< ElementPtr > () = ElementPtr(new StringElement("stdout", ctx.loc2pos(yystack_[0].location))); }
-#line 1225 "netconf_parser.cc" // lalr1.cc:856
+#line 1248 "netconf_parser.cc" // lalr1.cc:907
break;
case 122:
-#line 540 "netconf_parser.yy" // lalr1.cc:856
+#line 540 "netconf_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORDS);
}
-#line 1233 "netconf_parser.cc" // lalr1.cc:856
+#line 1256 "netconf_parser.cc" // lalr1.cc:907
break;
case 123:
-#line 542 "netconf_parser.yy" // lalr1.cc:856
+#line 542 "netconf_parser.yy" // lalr1.cc:907
{
ElementPtr name(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("socket-name", name);
ctx.leave();
}
-#line 1243 "netconf_parser.cc" // lalr1.cc:856
+#line 1266 "netconf_parser.cc" // lalr1.cc:907
break;
case 124:
-#line 549 "netconf_parser.yy" // lalr1.cc:856
+#line 549 "netconf_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORDS);
}
-#line 1251 "netconf_parser.cc" // lalr1.cc:856
+#line 1274 "netconf_parser.cc" // lalr1.cc:907
break;
case 125:
-#line 551 "netconf_parser.yy" // lalr1.cc:856
+#line 551 "netconf_parser.yy" // lalr1.cc:907
{
ElementPtr url(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("socket-url", url);
ctx.leave();
}
-#line 1261 "netconf_parser.cc" // lalr1.cc:856
+#line 1284 "netconf_parser.cc" // lalr1.cc:907
break;
case 126:
-#line 564 "netconf_parser.yy" // lalr1.cc:856
+#line 564 "netconf_parser.yy" // lalr1.cc:907
{
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("Logging", m);
ctx.stack_.push_back(m);
ctx.enter(ctx.LOGGING);
}
-#line 1272 "netconf_parser.cc" // lalr1.cc:856
+#line 1295 "netconf_parser.cc" // lalr1.cc:907
break;
case 127:
-#line 569 "netconf_parser.yy" // lalr1.cc:856
+#line 569 "netconf_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
ctx.leave();
}
-#line 1281 "netconf_parser.cc" // lalr1.cc:856
+#line 1304 "netconf_parser.cc" // lalr1.cc:907
break;
case 131:
-#line 586 "netconf_parser.yy" // lalr1.cc:856
+#line 586 "netconf_parser.yy" // lalr1.cc:907
{
ElementPtr l(new ListElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("loggers", l);
ctx.stack_.push_back(l);
ctx.enter(ctx.LOGGERS);
}
-#line 1292 "netconf_parser.cc" // lalr1.cc:856
+#line 1315 "netconf_parser.cc" // lalr1.cc:907
break;
case 132:
-#line 591 "netconf_parser.yy" // lalr1.cc:856
+#line 591 "netconf_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
ctx.leave();
}
-#line 1301 "netconf_parser.cc" // lalr1.cc:856
+#line 1324 "netconf_parser.cc" // lalr1.cc:907
break;
case 135:
-#line 603 "netconf_parser.yy" // lalr1.cc:856
+#line 603 "netconf_parser.yy" // lalr1.cc:907
{
ElementPtr l(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->add(l);
ctx.stack_.push_back(l);
}
-#line 1311 "netconf_parser.cc" // lalr1.cc:856
+#line 1334 "netconf_parser.cc" // lalr1.cc:907
break;
case 136:
-#line 607 "netconf_parser.yy" // lalr1.cc:856
+#line 607 "netconf_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
}
-#line 1319 "netconf_parser.cc" // lalr1.cc:856
+#line 1342 "netconf_parser.cc" // lalr1.cc:907
break;
case 146:
-#line 624 "netconf_parser.yy" // lalr1.cc:856
+#line 624 "netconf_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORDS);
}
-#line 1327 "netconf_parser.cc" // lalr1.cc:856
+#line 1350 "netconf_parser.cc" // lalr1.cc:907
break;
case 147:
-#line 626 "netconf_parser.yy" // lalr1.cc:856
+#line 626 "netconf_parser.yy" // lalr1.cc:907
{
ElementPtr name(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("name", name);
ctx.leave();
}
-#line 1337 "netconf_parser.cc" // lalr1.cc:856
+#line 1360 "netconf_parser.cc" // lalr1.cc:907
break;
case 148:
-#line 632 "netconf_parser.yy" // lalr1.cc:856
+#line 632 "netconf_parser.yy" // lalr1.cc:907
{
ElementPtr dl(new IntElement(yystack_[0].value.as< int64_t > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("debuglevel", dl);
}
-#line 1346 "netconf_parser.cc" // lalr1.cc:856
+#line 1369 "netconf_parser.cc" // lalr1.cc:907
break;
case 149:
-#line 637 "netconf_parser.yy" // lalr1.cc:856
+#line 637 "netconf_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORDS);
}
-#line 1354 "netconf_parser.cc" // lalr1.cc:856
+#line 1377 "netconf_parser.cc" // lalr1.cc:907
break;
case 150:
-#line 639 "netconf_parser.yy" // lalr1.cc:856
+#line 639 "netconf_parser.yy" // lalr1.cc:907
{
ElementPtr sev(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("severity", sev);
ctx.leave();
}
-#line 1364 "netconf_parser.cc" // lalr1.cc:856
+#line 1387 "netconf_parser.cc" // lalr1.cc:907
break;
case 151:
-#line 645 "netconf_parser.yy" // lalr1.cc:856
+#line 645 "netconf_parser.yy" // lalr1.cc:907
{
ElementPtr l(new ListElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("output_options", l);
ctx.stack_.push_back(l);
ctx.enter(ctx.OUTPUT_OPTIONS);
}
-#line 1375 "netconf_parser.cc" // lalr1.cc:856
+#line 1398 "netconf_parser.cc" // lalr1.cc:907
break;
case 152:
-#line 650 "netconf_parser.yy" // lalr1.cc:856
+#line 650 "netconf_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
ctx.leave();
}
-#line 1384 "netconf_parser.cc" // lalr1.cc:856
+#line 1407 "netconf_parser.cc" // lalr1.cc:907
break;
case 155:
-#line 659 "netconf_parser.yy" // lalr1.cc:856
+#line 659 "netconf_parser.yy" // lalr1.cc:907
{
ElementPtr m(new MapElement(ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->add(m);
ctx.stack_.push_back(m);
}
-#line 1394 "netconf_parser.cc" // lalr1.cc:856
+#line 1417 "netconf_parser.cc" // lalr1.cc:907
break;
case 156:
-#line 663 "netconf_parser.yy" // lalr1.cc:856
+#line 663 "netconf_parser.yy" // lalr1.cc:907
{
ctx.stack_.pop_back();
}
-#line 1402 "netconf_parser.cc" // lalr1.cc:856
+#line 1425 "netconf_parser.cc" // lalr1.cc:907
break;
case 163:
-#line 677 "netconf_parser.yy" // lalr1.cc:856
+#line 677 "netconf_parser.yy" // lalr1.cc:907
{
ctx.enter(ctx.NO_KEYWORDS);
}
-#line 1410 "netconf_parser.cc" // lalr1.cc:856
+#line 1433 "netconf_parser.cc" // lalr1.cc:907
break;
case 164:
-#line 679 "netconf_parser.yy" // lalr1.cc:856
+#line 679 "netconf_parser.yy" // lalr1.cc:907
{
ElementPtr sev(new StringElement(yystack_[0].value.as< std::string > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("output", sev);
ctx.leave();
}
-#line 1420 "netconf_parser.cc" // lalr1.cc:856
+#line 1443 "netconf_parser.cc" // lalr1.cc:907
break;
case 165:
-#line 685 "netconf_parser.yy" // lalr1.cc:856
+#line 685 "netconf_parser.yy" // lalr1.cc:907
{
ElementPtr flush(new BoolElement(yystack_[0].value.as< bool > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("flush", flush);
}
-#line 1429 "netconf_parser.cc" // lalr1.cc:856
+#line 1452 "netconf_parser.cc" // lalr1.cc:907
break;
case 166:
-#line 690 "netconf_parser.yy" // lalr1.cc:856
+#line 690 "netconf_parser.yy" // lalr1.cc:907
{
ElementPtr maxsize(new IntElement(yystack_[0].value.as< int64_t > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("maxsize", maxsize);
}
-#line 1438 "netconf_parser.cc" // lalr1.cc:856
+#line 1461 "netconf_parser.cc" // lalr1.cc:907
break;
case 167:
-#line 695 "netconf_parser.yy" // lalr1.cc:856
+#line 695 "netconf_parser.yy" // lalr1.cc:907
{
ElementPtr maxver(new IntElement(yystack_[0].value.as< int64_t > (), ctx.loc2pos(yystack_[0].location)));
ctx.stack_.back()->set("maxver", maxver);
}
-#line 1447 "netconf_parser.cc" // lalr1.cc:856
+#line 1470 "netconf_parser.cc" // lalr1.cc:907
break;
-#line 1451 "netconf_parser.cc" // lalr1.cc:856
+#line 1474 "netconf_parser.cc" // lalr1.cc:907
default:
break;
}
}
+#if YY_EXCEPTIONS
catch (const syntax_error& yyexc)
{
error (yyexc);
YYERROR;
}
+#endif // YY_EXCEPTIONS
YY_SYMBOL_PRINT ("-> $$ =", yylhs);
yypop_ (yylen);
yylen = 0;
YY_STACK_PRINT ();
// Shift the result of the reduction.
- yypush_ (YY_NULLPTR, yylhs);
+ yypush_ (YY_NULLPTR, YY_MOVE (yylhs));
}
goto yynewstate;
// Shift the error token.
error_token.state = yyn;
- yypush_ ("Shifting", error_token);
+ yypush_ ("Shifting", YY_MOVE (error_token));
}
goto yynewstate;
return yyresult;
}
+#if YY_EXCEPTIONS
catch (...)
{
YYCDEBUG << "Exception caught: cleaning lookahead and stack\n";
// Do not try to display the values of the reclaimed symbols,
- // as their printer might throw an exception.
+ // as their printers might throw an exception.
if (!yyla.empty ())
yy_destroy_ (YY_NULLPTR, yyla);
}
throw;
}
+#endif // YY_EXCEPTIONS
}
void
const signed char NetconfParser::yytable_ninf_ = -1;
- const short int
+ const short
NetconfParser::yypact_[] =
{
64, -64, -64, -64, 13, 9, 18, 29, -64, -64,
0, 0, 0, 156, 0, 165, 166, 167, 158, 164
};
- const short int
+ const short
NetconfParser::yypgoto_[] =
{
-64, -64, -64, -64, -64, -64, -64, -64, -20, 124,
-64, -64, -64
};
- const short int
+ const short
NetconfParser::yydefgoto_[] =
{
-1, 4, 5, 6, 7, 23, 27, 16, 17, 18,
264, 265, 266
};
- const unsigned short int
+ const unsigned short
NetconfParser::yytable_[] =
{
48, 55, 56, 52, 28, 40, 41, 59, 53, 54,
0, 0, 0, 0, 0, 0, 0, 0, 91
};
- const short int
+ const short
NetconfParser::yycheck_[] =
{
27, 27, 27, 27, 24, 11, 12, 6, 27, 27,
};
#if NETCONF_DEBUG
- const unsigned short int
+ const unsigned short
NetconfParser::yyrline_[] =
{
0, 118, 118, 118, 119, 119, 120, 120, 128, 128,
#endif // NETCONF_DEBUG
-#line 14 "netconf_parser.yy" // lalr1.cc:1163
+#line 14 "netconf_parser.yy" // lalr1.cc:1218
} } // isc::netconf
-#line 2040 "netconf_parser.cc" // lalr1.cc:1163
-#line 700 "netconf_parser.yy" // lalr1.cc:1164
+#line 2067 "netconf_parser.cc" // lalr1.cc:1218
+#line 700 "netconf_parser.yy" // lalr1.cc:1219
void
-// A Bison parser, made by GNU Bison 3.0.5.
+// A Bison parser, made by GNU Bison 3.2.1.
// Skeleton interface for Bison LALR(1) parsers in C++
// This special exception was added by the Free Software Foundation in
// version 2.2 of Bison.
+
/**
** \file netconf_parser.h
** Define the isc::netconf::parser class.
// C++ LALR(1) parser skeleton written by Akim Demaille.
+// Undocumented macros, especially those whose name start with YY_,
+// are private implementation details. Do not rely on them.
+
#ifndef YY_NETCONF_NETCONF_PARSER_H_INCLUDED
# define YY_NETCONF_NETCONF_PARSER_H_INCLUDED
// // "%code requires" blocks.
-#line 17 "netconf_parser.yy" // lalr1.cc:379
+#line 17 "netconf_parser.yy" // lalr1.cc:404
#include <string>
#include <cc/data.h>
using namespace isc::data;
using namespace std;
-#line 55 "netconf_parser.h" // lalr1.cc:379
+#line 59 "netconf_parser.h" // lalr1.cc:404
# include <cassert>
# include <cstdlib> // std::abort
# include <stdexcept>
# include <string>
# include <vector>
-# include "stack.hh"
+
+// Support move semantics when possible.
+#if defined __cplusplus && 201103L <= __cplusplus
+# define YY_MOVE std::move
+# define YY_MOVE_OR_COPY move
+# define YY_MOVE_REF(Type) Type&&
+# define YY_RVREF(Type) Type&&
+# define YY_COPY(Type) Type
+#else
+# define YY_MOVE
+# define YY_MOVE_OR_COPY copy
+# define YY_MOVE_REF(Type) Type&
+# define YY_RVREF(Type) const Type&
+# define YY_COPY(Type) const Type&
+#endif
# include "location.hh"
#include <typeinfo>
#ifndef YYASSERT
# define YY_ATTRIBUTE_UNUSED YY_ATTRIBUTE ((__unused__))
#endif
-#if !defined _Noreturn \
- && (!defined __STDC_VERSION__ || __STDC_VERSION__ < 201112)
-# if defined _MSC_VER && 1200 <= _MSC_VER
-# define _Noreturn __declspec (noreturn)
-# else
-# define _Noreturn YY_ATTRIBUTE ((__noreturn__))
-# endif
-#endif
-
/* Suppress unused-variable warnings by "using" E. */
#if ! defined lint || defined __GNUC__
# define YYUSE(E) ((void) (E))
# define YYUSE(E) /* empty */
#endif
-#if defined __GNUC__ && 407 <= __GNUC__ * 100 + __GNUC_MINOR__
+#if defined __GNUC__ && ! defined __ICC && 407 <= __GNUC__ * 100 + __GNUC_MINOR__
/* Suppress an incorrect diagnostic about yylval being uninitialized. */
# define YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN \
_Pragma ("GCC diagnostic push") \
# define YY_INITIAL_VALUE(Value) /* Nothing. */
#endif
+# ifndef YY_NULLPTR
+# if defined __cplusplus
+# if 201103L <= __cplusplus
+# define YY_NULLPTR nullptr
+# else
+# define YY_NULLPTR 0
+# endif
+# else
+# define YY_NULLPTR ((void*)0)
+# endif
+# endif
+
/* Debug traces. */
#ifndef NETCONF_DEBUG
# if defined YYDEBUG
# endif /* ! defined YYDEBUG */
#endif /* ! defined NETCONF_DEBUG */
-#line 14 "netconf_parser.yy" // lalr1.cc:379
+#line 14 "netconf_parser.yy" // lalr1.cc:404
namespace isc { namespace netconf {
-#line 140 "netconf_parser.h" // lalr1.cc:379
+#line 161 "netconf_parser.h" // lalr1.cc:404
+
+ /// A stack with random access from its top.
+ template <typename T, typename S = std::vector<T> >
+ class stack
+ {
+ public:
+ // Hide our reversed order.
+ typedef typename S::reverse_iterator iterator;
+ typedef typename S::const_reverse_iterator const_iterator;
+ typedef typename S::size_type size_type;
+
+ stack (size_type n = 200)
+ : seq_ (n)
+ {}
+
+ /// Random access.
+ ///
+ /// Index 0 returns the topmost element.
+ T&
+ operator[] (size_type i)
+ {
+ return seq_[size () - 1 - i];
+ }
+
+ /// Random access.
+ ///
+ /// Index 0 returns the topmost element.
+ T&
+ operator[] (int i)
+ {
+ return operator[] (size_type (i));
+ }
+
+ /// Random access.
+ ///
+ /// Index 0 returns the topmost element.
+ const T&
+ operator[] (size_type i) const
+ {
+ return seq_[size () - 1 - i];
+ }
+
+ /// Random access.
+ ///
+ /// Index 0 returns the topmost element.
+ const T&
+ operator[] (int i) const
+ {
+ return operator[] (size_type (i));
+ }
+
+ /// Steal the contents of \a t.
+ ///
+ /// Close to move-semantics.
+ void
+ push (YY_MOVE_REF (T) t)
+ {
+ seq_.push_back (T ());
+ operator[](0).move (t);
+ }
+
+ void
+ pop (int n = 1)
+ {
+ for (; 0 < n; --n)
+ seq_.pop_back ();
+ }
+
+ void
+ clear ()
+ {
+ seq_.clear ();
+ }
+
+ size_type
+ size () const
+ {
+ return seq_.size ();
+ }
+
+ const_iterator
+ begin () const
+ {
+ return seq_.rbegin ();
+ }
+
+ const_iterator
+ end () const
+ {
+ return seq_.rend ();
+ }
+
+ private:
+ stack (const stack&);
+ stack& operator= (const stack&);
+ /// The wrapped container.
+ S seq_;
+ };
+
+ /// Present a slice of the top of a stack.
+ template <typename T, typename S = stack<T> >
+ class slice
+ {
+ public:
+ slice (const S& stack, int range)
+ : stack_ (stack)
+ , range_ (range)
+ {}
+
+ const T&
+ operator[] (int i) const
+ {
+ return stack_[range_ - i];
+ }
+
+ private:
+ const S& stack_;
+ int range_;
+ };
/// Empty construction.
variant ()
- : yytypeid_ (YY_NULLPTR)
+ : yybuffer_ ()
+ , yytypeid_ (YY_NULLPTR)
{}
/// Construct and fill.
template <typename T>
- variant (const T& t)
+ variant (YY_RVREF (T) t)
: yytypeid_ (&typeid (T))
{
YYASSERT (sizeof (T) <= S);
- new (yyas_<T> ()) T (t);
+ new (yyas_<T> ()) T (YY_MOVE (t));
}
/// Destruction, allowed only if empty.
/// Instantiate an empty \a T in here.
template <typename T>
T&
- build ()
+ emplace ()
{
YYASSERT (!yytypeid_);
YYASSERT (sizeof (T) <= S);
yytypeid_ = & typeid (T);
- return *new (yyas_<T> ()) T;
+ return *new (yyas_<T> ()) T ();
}
+# if defined __cplusplus && 201103L <= __cplusplus
+ /// Instantiate a \a T in here from \a t.
+ template <typename T, typename U>
+ T&
+ emplace (U&& u)
+ {
+ YYASSERT (!yytypeid_);
+ YYASSERT (sizeof (T) <= S);
+ yytypeid_ = & typeid (T);
+ return *new (yyas_<T> ()) T (std::forward <U>(u));
+ }
+# else
/// Instantiate a \a T in here from \a t.
template <typename T>
T&
- build (const T& t)
+ emplace (const T& t)
{
YYASSERT (!yytypeid_);
YYASSERT (sizeof (T) <= S);
yytypeid_ = & typeid (T);
return *new (yyas_<T> ()) T (t);
}
+# endif
+
+ /// Instantiate an empty \a T in here.
+ /// Obsolete, use emplace.
+ template <typename T>
+ T&
+ build ()
+ {
+ return emplace<T> ();
+ }
+
+ /// Instantiate a \a T in here from \a t.
+ /// Obsolete, use emplace.
+ template <typename T>
+ T&
+ build (const T& t)
+ {
+ return emplace<T> (t);
+ }
/// Accessor to a built \a T.
template <typename T>
T&
as ()
{
+ YYASSERT (yytypeid_);
YYASSERT (*yytypeid_ == typeid (T));
YYASSERT (sizeof (T) <= S);
return *yyas_<T> ();
const T&
as () const
{
+ YYASSERT (yytypeid_);
YYASSERT (*yytypeid_ == typeid (T));
YYASSERT (sizeof (T) <= S);
return *yyas_<T> ();
/// Both variants must be built beforehand, because swapping the actual
/// data requires reading it (with as()), and this is not possible on
/// unconstructed variants: it would require some dynamic testing, which
- /// should not be the variant's responsability.
+ /// should not be the variant's responsibility.
/// Swapping between built and (possibly) non-built is done with
/// variant::move ().
template <typename T>
void
move (self_type& other)
{
- build<T> ();
+# if defined __cplusplus && 201103L <= __cplusplus
+ emplace<T> (std::move (other.as<T> ()));
+# else
+ emplace<T> ();
swap<T> (other);
+# endif
+ other.destroy<T> ();
+ }
+
+# if defined __cplusplus && 201103L <= __cplusplus
+ /// Move the content of \a other to this.
+ template <typename T>
+ void
+ move (self_type&& other)
+ {
+ emplace<T> (std::move (other.as<T> ()));
other.destroy<T> ();
}
+#endif
/// Copy the content of \a other to this.
template <typename T>
void
copy (const self_type& other)
{
- build<T> (other.as<T> ());
+ emplace<T> (other.as<T> ());
}
/// Destroy the stored \a T.
private:
/// Prohibit blind copies.
- self_type& operator=(const self_type&);
+ self_type& operator= (const self_type&);
variant (const self_type&);
/// Accessor to raw memory as \a T.
// value
// map_value
// socket_type_value
- char dummy1[sizeof(ElementPtr)];
+ char dummy1[sizeof (ElementPtr)];
// "boolean"
- char dummy2[sizeof(bool)];
+ char dummy2[sizeof (bool)];
// "floating point"
- char dummy3[sizeof(double)];
+ char dummy3[sizeof (double)];
// "integer"
- char dummy4[sizeof(int64_t)];
+ char dummy4[sizeof (int64_t)];
// "constant string"
- char dummy5[sizeof(std::string)];
+ char dummy5[sizeof (std::string)];
};
/// Symbol semantic values.
- typedef variant<sizeof(union_type)> semantic_type;
+ typedef variant<sizeof (union_type)> semantic_type;
#else
typedef NETCONF_STYPE semantic_type;
#endif
/// A complete symbol.
///
/// Expects its Base type to provide access to the symbol type
- /// via type_get().
+ /// via type_get ().
///
/// Provide access to semantic value and location.
template <typename Base>
/// Default constructor.
basic_symbol ();
- /// Copy constructor.
- basic_symbol (const basic_symbol& other);
-
- /// Constructor for valueless symbols, and symbols from each type.
-
- basic_symbol (typename Base::kind_type t, const location_type& l);
-
- basic_symbol (typename Base::kind_type t, const ElementPtr v, const location_type& l);
-
- basic_symbol (typename Base::kind_type t, const bool v, const location_type& l);
-
- basic_symbol (typename Base::kind_type t, const double v, const location_type& l);
-
- basic_symbol (typename Base::kind_type t, const int64_t v, const location_type& l);
+ /// Move or copy constructor.
+ basic_symbol (YY_RVREF (basic_symbol) other);
- basic_symbol (typename Base::kind_type t, const std::string v, const location_type& l);
+ /// Constructor for valueless symbols, and symbols from each type.
+ basic_symbol (typename Base::kind_type t, YY_RVREF (location_type) l);
+ basic_symbol (typename Base::kind_type t, YY_RVREF (ElementPtr) v, YY_RVREF (location_type) l);
+ basic_symbol (typename Base::kind_type t, YY_RVREF (bool) v, YY_RVREF (location_type) l);
+ basic_symbol (typename Base::kind_type t, YY_RVREF (double) v, YY_RVREF (location_type) l);
+ basic_symbol (typename Base::kind_type t, YY_RVREF (int64_t) v, YY_RVREF (location_type) l);
+ basic_symbol (typename Base::kind_type t, YY_RVREF (std::string) v, YY_RVREF (location_type) l);
- /// Constructor for symbols with semantic value.
- basic_symbol (typename Base::kind_type t,
- const semantic_type& v,
- const location_type& l);
/// Destroy the symbol.
~basic_symbol ();
location_type location;
private:
+#if !defined __cplusplus || __cplusplus < 201103L
/// Assignment operator.
basic_symbol& operator= (const basic_symbol& other);
+#endif
};
/// Type access provider for token (enum) based symbols.
/// "External" symbols: returned by the scanner.
typedef basic_symbol<by_type> symbol_type;
+ /// Build a parser object.
+ NetconfParser (isc::netconf::ParserContext& ctx_yyarg);
+ virtual ~NetconfParser ();
+
+ /// Parse. An alias for parse ().
+ /// \returns 0 iff parsing succeeded.
+ int operator() ();
+
+ /// Parse.
+ /// \returns 0 iff parsing succeeded.
+ virtual int parse ();
+
+#if NETCONF_DEBUG
+ /// The current debugging stream.
+ std::ostream& debug_stream () const YY_ATTRIBUTE_PURE;
+ /// Set the current debugging stream.
+ void set_debug_stream (std::ostream &);
+
+ /// Type for debugging levels.
+ typedef int debug_level_type;
+ /// The current debugging level.
+ debug_level_type debug_level () const YY_ATTRIBUTE_PURE;
+ /// Set the current debugging level.
+ void set_debug_level (debug_level_type l);
+#endif
+
+ /// Report a syntax error.
+ /// \param loc where the syntax error is found.
+ /// \param msg a description of the syntax error.
+ virtual void error (const location_type& loc, const std::string& msg);
+
+ /// Report a syntax error.
+ void error (const syntax_error& err);
+
// Symbol constructors declarations.
- static inline
+ static
symbol_type
- make_END (const location_type& l);
+ make_END (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_COMMA (const location_type& l);
+ make_COMMA (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_COLON (const location_type& l);
+ make_COLON (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_LSQUARE_BRACKET (const location_type& l);
+ make_LSQUARE_BRACKET (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_RSQUARE_BRACKET (const location_type& l);
+ make_RSQUARE_BRACKET (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_LCURLY_BRACKET (const location_type& l);
+ make_LCURLY_BRACKET (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_RCURLY_BRACKET (const location_type& l);
+ make_RCURLY_BRACKET (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_NULL_TYPE (const location_type& l);
+ make_NULL_TYPE (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_NETCONF (const location_type& l);
+ make_NETCONF (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_USER_CONTEXT (const location_type& l);
+ make_USER_CONTEXT (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_COMMENT (const location_type& l);
+ make_COMMENT (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_BOOT_UPDATE (const location_type& l);
+ make_BOOT_UPDATE (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_SUBSCRIBE_CHANGES (const location_type& l);
+ make_SUBSCRIBE_CHANGES (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_VALIDATE_CHANGES (const location_type& l);
+ make_VALIDATE_CHANGES (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_MANAGED_SERVERS (const location_type& l);
+ make_MANAGED_SERVERS (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_DHCP4_SERVER (const location_type& l);
+ make_DHCP4_SERVER (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_DHCP6_SERVER (const location_type& l);
+ make_DHCP6_SERVER (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_D2_SERVER (const location_type& l);
+ make_D2_SERVER (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_CA_SERVER (const location_type& l);
+ make_CA_SERVER (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_MODEL (const location_type& l);
+ make_MODEL (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_CONTROL_SOCKET (const location_type& l);
+ make_CONTROL_SOCKET (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_SOCKET_TYPE (const location_type& l);
+ make_SOCKET_TYPE (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_UNIX (const location_type& l);
+ make_UNIX (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_HTTP (const location_type& l);
+ make_HTTP (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_STDOUT (const location_type& l);
+ make_STDOUT (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_SOCKET_NAME (const location_type& l);
+ make_SOCKET_NAME (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_SOCKET_URL (const location_type& l);
+ make_SOCKET_URL (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_HOOKS_LIBRARIES (const location_type& l);
+ make_HOOKS_LIBRARIES (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_LIBRARY (const location_type& l);
+ make_LIBRARY (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_PARAMETERS (const location_type& l);
+ make_PARAMETERS (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_LOGGING (const location_type& l);
+ make_LOGGING (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_LOGGERS (const location_type& l);
+ make_LOGGERS (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_NAME (const location_type& l);
+ make_NAME (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_OUTPUT_OPTIONS (const location_type& l);
+ make_OUTPUT_OPTIONS (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_OUTPUT (const location_type& l);
+ make_OUTPUT (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_DEBUGLEVEL (const location_type& l);
+ make_DEBUGLEVEL (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_SEVERITY (const location_type& l);
+ make_SEVERITY (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_FLUSH (const location_type& l);
+ make_FLUSH (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_MAXSIZE (const location_type& l);
+ make_MAXSIZE (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_MAXVER (const location_type& l);
+ make_MAXVER (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_START_JSON (const location_type& l);
+ make_START_JSON (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_START_NETCONF (const location_type& l);
+ make_START_NETCONF (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_START_SUB_NETCONF (const location_type& l);
+ make_START_SUB_NETCONF (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_STRING (const std::string& v, const location_type& l);
+ make_STRING (YY_COPY (std::string) v, YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_INTEGER (const int64_t& v, const location_type& l);
+ make_INTEGER (YY_COPY (int64_t) v, YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_FLOAT (const double& v, const location_type& l);
+ make_FLOAT (YY_COPY (double) v, YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_BOOLEAN (const bool& v, const location_type& l);
-
-
- /// Build a parser object.
- NetconfParser (isc::netconf::ParserContext& ctx_yyarg);
- virtual ~NetconfParser ();
+ make_BOOLEAN (YY_COPY (bool) v, YY_COPY (location_type) l);
- /// Parse.
- /// \returns 0 iff parsing succeeded.
- virtual int parse ();
-#if NETCONF_DEBUG
- /// The current debugging stream.
- std::ostream& debug_stream () const YY_ATTRIBUTE_PURE;
- /// Set the current debugging stream.
- void set_debug_stream (std::ostream &);
-
- /// Type for debugging levels.
- typedef int debug_level_type;
- /// The current debugging level.
- debug_level_type debug_level () const YY_ATTRIBUTE_PURE;
- /// Set the current debugging level.
- void set_debug_level (debug_level_type l);
-#endif
-
- /// Report a syntax error.
- /// \param loc where the syntax error is found.
- /// \param msg a description of the syntax error.
- virtual void error (const location_type& loc, const std::string& msg);
-
- /// Report a syntax error.
- void error (const syntax_error& err);
private:
/// This class is not copyable.
// Tables.
// YYPACT[STATE-NUM] -- Index in YYTABLE of the portion describing
// STATE-NUM.
- static const short int yypact_[];
+ static const short yypact_[];
// YYDEFACT[STATE-NUM] -- Default reduction number in state STATE-NUM.
// Performed when YYTABLE does not specify something else to do. Zero
static const unsigned char yydefact_[];
// YYPGOTO[NTERM-NUM].
- static const short int yypgoto_[];
+ static const short yypgoto_[];
// YYDEFGOTO[NTERM-NUM].
- static const short int yydefgoto_[];
+ static const short yydefgoto_[];
// YYTABLE[YYPACT[STATE-NUM]] -- What to do in state STATE-NUM. If
// positive, shift that token. If negative, reduce the rule whose
// number is the opposite. If YYTABLE_NINF, syntax error.
- static const unsigned short int yytable_[];
+ static const unsigned short yytable_[];
- static const short int yycheck_[];
+ static const short yycheck_[];
// YYSTOS[STATE-NUM] -- The (internal number of the) accessing
// symbol of state STATE-NUM.
static const char* const yytname_[];
#if NETCONF_DEBUG
// YYRLINE[YYN] -- Source line where rule number YYN was defined.
- static const unsigned short int yyrline_[];
+ static const unsigned short yyrline_[];
/// Report on the debug stream that the rule \a r is going to be reduced.
virtual void yy_reduce_print_ (int r);
/// Print the state stack on the debug stream.
virtual void yystack_print_ ();
- // Debugging.
+ /// Debugging level.
int yydebug_;
+ /// Debug stream.
std::ostream* yycdebug_;
/// \brief Display a symbol type, value and location.
typedef basic_symbol<by_state> super_type;
/// Construct an empty symbol.
stack_symbol_type ();
- /// Copy construct.
- stack_symbol_type (const stack_symbol_type& that);
+ /// Move or copy construction.
+ stack_symbol_type (YY_RVREF (stack_symbol_type) that);
/// Steal the contents from \a sym to build this.
- stack_symbol_type (state_type s, symbol_type& sym);
- /// Assignment, needed by push_back.
- stack_symbol_type& operator= (const stack_symbol_type& that);
+ stack_symbol_type (state_type s, YY_MOVE_REF (symbol_type) sym);
+#if !defined __cplusplus || __cplusplus < 201103L
+ /// Assignment, needed by push_back by some old implementations.
+ /// Moves the contents of that.
+ stack_symbol_type& operator= (stack_symbol_type& that);
+#endif
};
/// Stack type.
/// Push a new state on the stack.
/// \param m a debug message to display
/// if null, no trace is output.
- /// \param s the symbol
+ /// \param sym the symbol
/// \warning the contents of \a s.value is stolen.
- void yypush_ (const char* m, stack_symbol_type& s);
+ void yypush_ (const char* m, YY_MOVE_REF (stack_symbol_type) sym);
/// Push a new look ahead token on the state on the stack.
/// \param m a debug message to display
/// if null, no trace is output.
/// \param s the state
/// \param sym the symbol (for its value and location).
- /// \warning the contents of \a s.value is stolen.
- void yypush_ (const char* m, state_type s, symbol_type& sym);
+ /// \warning the contents of \a sym.value is stolen.
+ void yypush_ (const char* m, state_type s, YY_MOVE_REF (symbol_type) sym);
- /// Pop \a n symbols the three stacks.
- void yypop_ (unsigned n = 1);
+ /// Pop \a n symbols from the stack.
+ void yypop_ (int n = 1);
/// Constants.
enum
template <typename Base>
NetconfParser::basic_symbol<Base>::basic_symbol ()
: value ()
+ , location ()
{}
template <typename Base>
- NetconfParser::basic_symbol<Base>::basic_symbol (const basic_symbol& other)
- : Base (other)
+ NetconfParser::basic_symbol<Base>::basic_symbol (YY_RVREF (basic_symbol) other)
+ : Base (YY_MOVE (other))
, value ()
- , location (other.location)
+ , location (YY_MOVE (other.location))
{
switch (other.type_get ())
{
case 57: // value
case 60: // map_value
case 119: // socket_type_value
- value.copy< ElementPtr > (other.value);
+ value.YY_MOVE_OR_COPY< ElementPtr > (YY_MOVE (other.value));
break;
case 48: // "boolean"
- value.copy< bool > (other.value);
+ value.YY_MOVE_OR_COPY< bool > (YY_MOVE (other.value));
break;
case 47: // "floating point"
- value.copy< double > (other.value);
+ value.YY_MOVE_OR_COPY< double > (YY_MOVE (other.value));
break;
case 46: // "integer"
- value.copy< int64_t > (other.value);
+ value.YY_MOVE_OR_COPY< int64_t > (YY_MOVE (other.value));
break;
case 45: // "constant string"
- value.copy< std::string > (other.value);
+ value.YY_MOVE_OR_COPY< std::string > (YY_MOVE (other.value));
break;
default:
}
- template <typename Base>
- NetconfParser::basic_symbol<Base>::basic_symbol (typename Base::kind_type t, const semantic_type& v, const location_type& l)
- : Base (t)
- , value ()
- , location (l)
- {
- (void) v;
- switch (this->type_get ())
- {
- case 57: // value
- case 60: // map_value
- case 119: // socket_type_value
- value.copy< ElementPtr > (v);
- break;
-
- case 48: // "boolean"
- value.copy< bool > (v);
- break;
-
- case 47: // "floating point"
- value.copy< double > (v);
- break;
-
- case 46: // "integer"
- value.copy< int64_t > (v);
- break;
-
- case 45: // "constant string"
- value.copy< std::string > (v);
- break;
-
- default:
- break;
- }
-}
-
// Implementation of basic_symbol constructor for each type.
-
template <typename Base>
- NetconfParser::basic_symbol<Base>::basic_symbol (typename Base::kind_type t, const location_type& l)
+ NetconfParser::basic_symbol<Base>::basic_symbol (typename Base::kind_type t, YY_RVREF (location_type) l)
: Base (t)
- , value ()
- , location (l)
+ , location (YY_MOVE (l))
{}
template <typename Base>
- NetconfParser::basic_symbol<Base>::basic_symbol (typename Base::kind_type t, const ElementPtr v, const location_type& l)
+ NetconfParser::basic_symbol<Base>::basic_symbol (typename Base::kind_type t, YY_RVREF (ElementPtr) v, YY_RVREF (location_type) l)
: Base (t)
- , value (v)
- , location (l)
+ , value (YY_MOVE (v))
+ , location (YY_MOVE (l))
{}
template <typename Base>
- NetconfParser::basic_symbol<Base>::basic_symbol (typename Base::kind_type t, const bool v, const location_type& l)
+ NetconfParser::basic_symbol<Base>::basic_symbol (typename Base::kind_type t, YY_RVREF (bool) v, YY_RVREF (location_type) l)
: Base (t)
- , value (v)
- , location (l)
+ , value (YY_MOVE (v))
+ , location (YY_MOVE (l))
{}
template <typename Base>
- NetconfParser::basic_symbol<Base>::basic_symbol (typename Base::kind_type t, const double v, const location_type& l)
+ NetconfParser::basic_symbol<Base>::basic_symbol (typename Base::kind_type t, YY_RVREF (double) v, YY_RVREF (location_type) l)
: Base (t)
- , value (v)
- , location (l)
+ , value (YY_MOVE (v))
+ , location (YY_MOVE (l))
{}
template <typename Base>
- NetconfParser::basic_symbol<Base>::basic_symbol (typename Base::kind_type t, const int64_t v, const location_type& l)
+ NetconfParser::basic_symbol<Base>::basic_symbol (typename Base::kind_type t, YY_RVREF (int64_t) v, YY_RVREF (location_type) l)
: Base (t)
- , value (v)
- , location (l)
+ , value (YY_MOVE (v))
+ , location (YY_MOVE (l))
{}
template <typename Base>
- NetconfParser::basic_symbol<Base>::basic_symbol (typename Base::kind_type t, const std::string v, const location_type& l)
+ NetconfParser::basic_symbol<Base>::basic_symbol (typename Base::kind_type t, YY_RVREF (std::string) v, YY_RVREF (location_type) l)
: Base (t)
- , value (v)
- , location (l)
+ , value (YY_MOVE (v))
+ , location (YY_MOVE (l))
{}
+
template <typename Base>
NetconfParser::basic_symbol<Base>::~basic_symbol ()
{
case 57: // value
case 60: // map_value
case 119: // socket_type_value
- value.move< ElementPtr > (s.value);
+ value.move< ElementPtr > (YY_MOVE (s.value));
break;
case 48: // "boolean"
- value.move< bool > (s.value);
+ value.move< bool > (YY_MOVE (s.value));
break;
case 47: // "floating point"
- value.move< double > (s.value);
+ value.move< double > (YY_MOVE (s.value));
break;
case 46: // "integer"
- value.move< int64_t > (s.value);
+ value.move< int64_t > (YY_MOVE (s.value));
break;
case 45: // "constant string"
- value.move< std::string > (s.value);
+ value.move< std::string > (YY_MOVE (s.value));
break;
default:
break;
}
- location = s.location;
+ location = YY_MOVE (s.location);
}
// by_type.
// YYTOKNUM[NUM] -- (External) token number corresponding to the
// (internal) symbol number NUM (which must be that of a token). */
static
- const unsigned short int
+ const unsigned short
yytoken_number_[] =
{
0, 256, 257, 258, 259, 260, 261, 262, 263, 264,
};
return static_cast<token_type> (yytoken_number_[type]);
}
+
// Implementation of make_symbol for each symbol type.
+ inline
NetconfParser::symbol_type
- NetconfParser::make_END (const location_type& l)
+ NetconfParser::make_END (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_END, l);
+ return symbol_type (token::TOKEN_END, YY_MOVE (l));
}
+ inline
NetconfParser::symbol_type
- NetconfParser::make_COMMA (const location_type& l)
+ NetconfParser::make_COMMA (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_COMMA, l);
+ return symbol_type (token::TOKEN_COMMA, YY_MOVE (l));
}
+ inline
NetconfParser::symbol_type
- NetconfParser::make_COLON (const location_type& l)
+ NetconfParser::make_COLON (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_COLON, l);
+ return symbol_type (token::TOKEN_COLON, YY_MOVE (l));
}
+ inline
NetconfParser::symbol_type
- NetconfParser::make_LSQUARE_BRACKET (const location_type& l)
+ NetconfParser::make_LSQUARE_BRACKET (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_LSQUARE_BRACKET, l);
+ return symbol_type (token::TOKEN_LSQUARE_BRACKET, YY_MOVE (l));
}
+ inline
NetconfParser::symbol_type
- NetconfParser::make_RSQUARE_BRACKET (const location_type& l)
+ NetconfParser::make_RSQUARE_BRACKET (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_RSQUARE_BRACKET, l);
+ return symbol_type (token::TOKEN_RSQUARE_BRACKET, YY_MOVE (l));
}
+ inline
NetconfParser::symbol_type
- NetconfParser::make_LCURLY_BRACKET (const location_type& l)
+ NetconfParser::make_LCURLY_BRACKET (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_LCURLY_BRACKET, l);
+ return symbol_type (token::TOKEN_LCURLY_BRACKET, YY_MOVE (l));
}
+ inline
NetconfParser::symbol_type
- NetconfParser::make_RCURLY_BRACKET (const location_type& l)
+ NetconfParser::make_RCURLY_BRACKET (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_RCURLY_BRACKET, l);
+ return symbol_type (token::TOKEN_RCURLY_BRACKET, YY_MOVE (l));
}
+ inline
NetconfParser::symbol_type
- NetconfParser::make_NULL_TYPE (const location_type& l)
+ NetconfParser::make_NULL_TYPE (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_NULL_TYPE, l);
+ return symbol_type (token::TOKEN_NULL_TYPE, YY_MOVE (l));
}
+ inline
NetconfParser::symbol_type
- NetconfParser::make_NETCONF (const location_type& l)
+ NetconfParser::make_NETCONF (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_NETCONF, l);
+ return symbol_type (token::TOKEN_NETCONF, YY_MOVE (l));
}
+ inline
NetconfParser::symbol_type
- NetconfParser::make_USER_CONTEXT (const location_type& l)
+ NetconfParser::make_USER_CONTEXT (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_USER_CONTEXT, l);
+ return symbol_type (token::TOKEN_USER_CONTEXT, YY_MOVE (l));
}
+ inline
NetconfParser::symbol_type
- NetconfParser::make_COMMENT (const location_type& l)
+ NetconfParser::make_COMMENT (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_COMMENT, l);
+ return symbol_type (token::TOKEN_COMMENT, YY_MOVE (l));
}
+ inline
NetconfParser::symbol_type
- NetconfParser::make_BOOT_UPDATE (const location_type& l)
+ NetconfParser::make_BOOT_UPDATE (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_BOOT_UPDATE, l);
+ return symbol_type (token::TOKEN_BOOT_UPDATE, YY_MOVE (l));
}
+ inline
NetconfParser::symbol_type
- NetconfParser::make_SUBSCRIBE_CHANGES (const location_type& l)
+ NetconfParser::make_SUBSCRIBE_CHANGES (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_SUBSCRIBE_CHANGES, l);
+ return symbol_type (token::TOKEN_SUBSCRIBE_CHANGES, YY_MOVE (l));
}
+ inline
NetconfParser::symbol_type
- NetconfParser::make_VALIDATE_CHANGES (const location_type& l)
+ NetconfParser::make_VALIDATE_CHANGES (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_VALIDATE_CHANGES, l);
+ return symbol_type (token::TOKEN_VALIDATE_CHANGES, YY_MOVE (l));
}
+ inline
NetconfParser::symbol_type
- NetconfParser::make_MANAGED_SERVERS (const location_type& l)
+ NetconfParser::make_MANAGED_SERVERS (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_MANAGED_SERVERS, l);
+ return symbol_type (token::TOKEN_MANAGED_SERVERS, YY_MOVE (l));
}
+ inline
NetconfParser::symbol_type
- NetconfParser::make_DHCP4_SERVER (const location_type& l)
+ NetconfParser::make_DHCP4_SERVER (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_DHCP4_SERVER, l);
+ return symbol_type (token::TOKEN_DHCP4_SERVER, YY_MOVE (l));
}
+ inline
NetconfParser::symbol_type
- NetconfParser::make_DHCP6_SERVER (const location_type& l)
+ NetconfParser::make_DHCP6_SERVER (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_DHCP6_SERVER, l);
+ return symbol_type (token::TOKEN_DHCP6_SERVER, YY_MOVE (l));
}
+ inline
NetconfParser::symbol_type
- NetconfParser::make_D2_SERVER (const location_type& l)
+ NetconfParser::make_D2_SERVER (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_D2_SERVER, l);
+ return symbol_type (token::TOKEN_D2_SERVER, YY_MOVE (l));
}
+ inline
NetconfParser::symbol_type
- NetconfParser::make_CA_SERVER (const location_type& l)
+ NetconfParser::make_CA_SERVER (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_CA_SERVER, l);
+ return symbol_type (token::TOKEN_CA_SERVER, YY_MOVE (l));
}
+ inline
NetconfParser::symbol_type
- NetconfParser::make_MODEL (const location_type& l)
+ NetconfParser::make_MODEL (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_MODEL, l);
+ return symbol_type (token::TOKEN_MODEL, YY_MOVE (l));
}
+ inline
NetconfParser::symbol_type
- NetconfParser::make_CONTROL_SOCKET (const location_type& l)
+ NetconfParser::make_CONTROL_SOCKET (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_CONTROL_SOCKET, l);
+ return symbol_type (token::TOKEN_CONTROL_SOCKET, YY_MOVE (l));
}
+ inline
NetconfParser::symbol_type
- NetconfParser::make_SOCKET_TYPE (const location_type& l)
+ NetconfParser::make_SOCKET_TYPE (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_SOCKET_TYPE, l);
+ return symbol_type (token::TOKEN_SOCKET_TYPE, YY_MOVE (l));
}
+ inline
NetconfParser::symbol_type
- NetconfParser::make_UNIX (const location_type& l)
+ NetconfParser::make_UNIX (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_UNIX, l);
+ return symbol_type (token::TOKEN_UNIX, YY_MOVE (l));
}
+ inline
NetconfParser::symbol_type
- NetconfParser::make_HTTP (const location_type& l)
+ NetconfParser::make_HTTP (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_HTTP, l);
+ return symbol_type (token::TOKEN_HTTP, YY_MOVE (l));
}
+ inline
NetconfParser::symbol_type
- NetconfParser::make_STDOUT (const location_type& l)
+ NetconfParser::make_STDOUT (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_STDOUT, l);
+ return symbol_type (token::TOKEN_STDOUT, YY_MOVE (l));
}
+ inline
NetconfParser::symbol_type
- NetconfParser::make_SOCKET_NAME (const location_type& l)
+ NetconfParser::make_SOCKET_NAME (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_SOCKET_NAME, l);
+ return symbol_type (token::TOKEN_SOCKET_NAME, YY_MOVE (l));
}
+ inline
NetconfParser::symbol_type
- NetconfParser::make_SOCKET_URL (const location_type& l)
+ NetconfParser::make_SOCKET_URL (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_SOCKET_URL, l);
+ return symbol_type (token::TOKEN_SOCKET_URL, YY_MOVE (l));
}
+ inline
NetconfParser::symbol_type
- NetconfParser::make_HOOKS_LIBRARIES (const location_type& l)
+ NetconfParser::make_HOOKS_LIBRARIES (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_HOOKS_LIBRARIES, l);
+ return symbol_type (token::TOKEN_HOOKS_LIBRARIES, YY_MOVE (l));
}
+ inline
NetconfParser::symbol_type
- NetconfParser::make_LIBRARY (const location_type& l)
+ NetconfParser::make_LIBRARY (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_LIBRARY, l);
+ return symbol_type (token::TOKEN_LIBRARY, YY_MOVE (l));
}
+ inline
NetconfParser::symbol_type
- NetconfParser::make_PARAMETERS (const location_type& l)
+ NetconfParser::make_PARAMETERS (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_PARAMETERS, l);
+ return symbol_type (token::TOKEN_PARAMETERS, YY_MOVE (l));
}
+ inline
NetconfParser::symbol_type
- NetconfParser::make_LOGGING (const location_type& l)
+ NetconfParser::make_LOGGING (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_LOGGING, l);
+ return symbol_type (token::TOKEN_LOGGING, YY_MOVE (l));
}
+ inline
NetconfParser::symbol_type
- NetconfParser::make_LOGGERS (const location_type& l)
+ NetconfParser::make_LOGGERS (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_LOGGERS, l);
+ return symbol_type (token::TOKEN_LOGGERS, YY_MOVE (l));
}
+ inline
NetconfParser::symbol_type
- NetconfParser::make_NAME (const location_type& l)
+ NetconfParser::make_NAME (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_NAME, l);
+ return symbol_type (token::TOKEN_NAME, YY_MOVE (l));
}
+ inline
NetconfParser::symbol_type
- NetconfParser::make_OUTPUT_OPTIONS (const location_type& l)
+ NetconfParser::make_OUTPUT_OPTIONS (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_OUTPUT_OPTIONS, l);
+ return symbol_type (token::TOKEN_OUTPUT_OPTIONS, YY_MOVE (l));
}
+ inline
NetconfParser::symbol_type
- NetconfParser::make_OUTPUT (const location_type& l)
+ NetconfParser::make_OUTPUT (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_OUTPUT, l);
+ return symbol_type (token::TOKEN_OUTPUT, YY_MOVE (l));
}
+ inline
NetconfParser::symbol_type
- NetconfParser::make_DEBUGLEVEL (const location_type& l)
+ NetconfParser::make_DEBUGLEVEL (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_DEBUGLEVEL, l);
+ return symbol_type (token::TOKEN_DEBUGLEVEL, YY_MOVE (l));
}
+ inline
NetconfParser::symbol_type
- NetconfParser::make_SEVERITY (const location_type& l)
+ NetconfParser::make_SEVERITY (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_SEVERITY, l);
+ return symbol_type (token::TOKEN_SEVERITY, YY_MOVE (l));
}
+ inline
NetconfParser::symbol_type
- NetconfParser::make_FLUSH (const location_type& l)
+ NetconfParser::make_FLUSH (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_FLUSH, l);
+ return symbol_type (token::TOKEN_FLUSH, YY_MOVE (l));
}
+ inline
NetconfParser::symbol_type
- NetconfParser::make_MAXSIZE (const location_type& l)
+ NetconfParser::make_MAXSIZE (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_MAXSIZE, l);
+ return symbol_type (token::TOKEN_MAXSIZE, YY_MOVE (l));
}
+ inline
NetconfParser::symbol_type
- NetconfParser::make_MAXVER (const location_type& l)
+ NetconfParser::make_MAXVER (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_MAXVER, l);
+ return symbol_type (token::TOKEN_MAXVER, YY_MOVE (l));
}
+ inline
NetconfParser::symbol_type
- NetconfParser::make_START_JSON (const location_type& l)
+ NetconfParser::make_START_JSON (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_START_JSON, l);
+ return symbol_type (token::TOKEN_START_JSON, YY_MOVE (l));
}
+ inline
NetconfParser::symbol_type
- NetconfParser::make_START_NETCONF (const location_type& l)
+ NetconfParser::make_START_NETCONF (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_START_NETCONF, l);
+ return symbol_type (token::TOKEN_START_NETCONF, YY_MOVE (l));
}
+ inline
NetconfParser::symbol_type
- NetconfParser::make_START_SUB_NETCONF (const location_type& l)
+ NetconfParser::make_START_SUB_NETCONF (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_START_SUB_NETCONF, l);
+ return symbol_type (token::TOKEN_START_SUB_NETCONF, YY_MOVE (l));
}
+ inline
NetconfParser::symbol_type
- NetconfParser::make_STRING (const std::string& v, const location_type& l)
+ NetconfParser::make_STRING (YY_COPY (std::string) v, YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_STRING, v, l);
+ return symbol_type (token::TOKEN_STRING, YY_MOVE (v), YY_MOVE (l));
}
+ inline
NetconfParser::symbol_type
- NetconfParser::make_INTEGER (const int64_t& v, const location_type& l)
+ NetconfParser::make_INTEGER (YY_COPY (int64_t) v, YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_INTEGER, v, l);
+ return symbol_type (token::TOKEN_INTEGER, YY_MOVE (v), YY_MOVE (l));
}
+ inline
NetconfParser::symbol_type
- NetconfParser::make_FLOAT (const double& v, const location_type& l)
+ NetconfParser::make_FLOAT (YY_COPY (double) v, YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_FLOAT, v, l);
+ return symbol_type (token::TOKEN_FLOAT, YY_MOVE (v), YY_MOVE (l));
}
+ inline
NetconfParser::symbol_type
- NetconfParser::make_BOOLEAN (const bool& v, const location_type& l)
+ NetconfParser::make_BOOLEAN (YY_COPY (bool) v, YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_BOOLEAN, v, l);
+ return symbol_type (token::TOKEN_BOOLEAN, YY_MOVE (v), YY_MOVE (l));
}
-#line 14 "netconf_parser.yy" // lalr1.cc:379
+#line 14 "netconf_parser.yy" // lalr1.cc:404
} } // isc::netconf
-#line 1533 "netconf_parser.h" // lalr1.cc:379
+#line 1735 "netconf_parser.h" // lalr1.cc:404
-// Generated 201811151407
-// A Bison parser, made by GNU Bison 3.0.5.
-
-// Positions for Bison parsers in C++
-
-// Copyright (C) 2002-2015, 2018 Free Software Foundation, Inc.
-
-// This program is free software: you can redistribute it and/or modify
-// it under the terms of the GNU General Public License as published by
-// the Free Software Foundation, either version 3 of the License, or
-// (at your option) any later version.
-
-// This program is distributed in the hope that it will be useful,
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-// GNU General Public License for more details.
-
-// You should have received a copy of the GNU General Public License
-// along with this program. If not, see <http://www.gnu.org/licenses/>.
-
-// As a special exception, you may create a larger work that contains
-// part or all of the Bison parser skeleton and distribute that work
-// under terms of your choice, so long as that work isn't itself a
-// parser generator using the skeleton or a modified version thereof
-// as a parser skeleton. Alternatively, if you modify or redistribute
-// the parser skeleton itself, you may (at your option) remove this
-// special exception, which will cause the skeleton and the resulting
-// Bison output files to be licensed under the GNU General Public
-// License without this special exception.
-
-// This special exception was added by the Free Software Foundation in
-// version 2.2 of Bison.
-
-/**
- ** \file position.hh
- ** Define the isc::netconf::position class.
- */
-
-#ifndef YY_NETCONF_POSITION_HH_INCLUDED
-# define YY_NETCONF_POSITION_HH_INCLUDED
-
-# include <algorithm> // std::max
-# include <iostream>
-# include <string>
-
-# ifndef YY_NULLPTR
-# if defined __cplusplus && 201103L <= __cplusplus
-# define YY_NULLPTR nullptr
-# else
-# define YY_NULLPTR 0
-# endif
-# endif
-
-#line 14 "netconf_parser.yy" // location.cc:292
-namespace isc { namespace netconf {
-#line 56 "position.hh" // location.cc:292
- /// Abstract a position.
- class position
- {
- public:
- /// Construct a position.
- explicit position (std::string* f = YY_NULLPTR,
- unsigned l = 1u,
- unsigned c = 1u)
- : filename (f)
- , line (l)
- , column (c)
- {}
-
-
- /// Initialization.
- void initialize (std::string* fn = YY_NULLPTR,
- unsigned l = 1u,
- unsigned c = 1u)
- {
- filename = fn;
- line = l;
- column = c;
- }
-
- /** \name Line and Column related manipulators
- ** \{ */
- /// (line related) Advance to the COUNT next lines.
- void lines (int count = 1)
- {
- if (count)
- {
- column = 1u;
- line = add_ (line, count, 1);
- }
- }
-
- /// (column related) Advance to the COUNT next columns.
- void columns (int count = 1)
- {
- column = add_ (column, count, 1);
- }
- /** \} */
-
- /// File name to which this position refers.
- std::string* filename;
- /// Current line number.
- unsigned line;
- /// Current column number.
- unsigned column;
-
- private:
- /// Compute max(min, lhs+rhs) (provided min <= lhs).
- static unsigned add_ (unsigned lhs, int rhs, unsigned min)
- {
- return (0 < rhs || -static_cast<unsigned>(rhs) < lhs
- ? rhs + lhs
- : min);
- }
- };
-
- /// Add \a width columns, in place.
- inline position&
- operator+= (position& res, int width)
- {
- res.columns (width);
- return res;
- }
-
- /// Add \a width columns.
- inline position
- operator+ (position res, int width)
- {
- return res += width;
- }
-
- /// Subtract \a width columns, in place.
- inline position&
- operator-= (position& res, int width)
- {
- return res += -width;
- }
-
- /// Subtract \a width columns.
- inline position
- operator- (position res, int width)
- {
- return res -= width;
- }
-
- /// Compare two position objects.
- inline bool
- operator== (const position& pos1, const position& pos2)
- {
- return (pos1.line == pos2.line
- && pos1.column == pos2.column
- && (pos1.filename == pos2.filename
- || (pos1.filename && pos2.filename
- && *pos1.filename == *pos2.filename)));
- }
-
- /// Compare two position objects.
- inline bool
- operator!= (const position& pos1, const position& pos2)
- {
- return !(pos1 == pos2);
- }
-
- /** \brief Intercept output stream redirection.
- ** \param ostr the destination output stream
- ** \param pos a reference to the position to redirect
- */
- template <typename YYChar>
- inline std::basic_ostream<YYChar>&
- operator<< (std::basic_ostream<YYChar>& ostr, const position& pos)
- {
- if (pos.filename)
- ostr << *pos.filename << ':';
- return ostr << pos.line << '.' << pos.column;
- }
-
-#line 14 "netconf_parser.yy" // location.cc:292
-} } // isc::netconf
-#line 179 "position.hh" // location.cc:292
-#endif // !YY_NETCONF_POSITION_HH_INCLUDED
+// Generated 201811172153
+// A Bison parser, made by GNU Bison 3.2.1.
+
+// Starting with Bison 3.2, this file is useless: the structure it
+// used to define is now defined in "location.hh".
+//
+// To get rid of this file:
+// 1. add 'require "3.2"' (or newer) to your grammar file
+// 2. remove references to this file from your build system
+// 3. if you used to include it, include "location.hh" instead.
+
+#include "location.hh"
-// Generated 201811151407
-// A Bison parser, made by GNU Bison 3.0.5.
-
-// Stack handling for Bison parsers in C++
-
-// Copyright (C) 2002-2015, 2018 Free Software Foundation, Inc.
-
-// This program is free software: you can redistribute it and/or modify
-// it under the terms of the GNU General Public License as published by
-// the Free Software Foundation, either version 3 of the License, or
-// (at your option) any later version.
-
-// This program is distributed in the hope that it will be useful,
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-// GNU General Public License for more details.
-
-// You should have received a copy of the GNU General Public License
-// along with this program. If not, see <http://www.gnu.org/licenses/>.
-
-// As a special exception, you may create a larger work that contains
-// part or all of the Bison parser skeleton and distribute that work
-// under terms of your choice, so long as that work isn't itself a
-// parser generator using the skeleton or a modified version thereof
-// as a parser skeleton. Alternatively, if you modify or redistribute
-// the parser skeleton itself, you may (at your option) remove this
-// special exception, which will cause the skeleton and the resulting
-// Bison output files to be licensed under the GNU General Public
-// License without this special exception.
-
-// This special exception was added by the Free Software Foundation in
-// version 2.2 of Bison.
-
-/**
- ** \file stack.hh
- ** Define the isc::netconf::stack class.
- */
-
-#ifndef YY_NETCONF_STACK_HH_INCLUDED
-# define YY_NETCONF_STACK_HH_INCLUDED
-
-# include <vector>
-
-#line 14 "netconf_parser.yy" // stack.hh:131
-namespace isc { namespace netconf {
-#line 46 "stack.hh" // stack.hh:131
- /// A stack with random access from its top.
- template <class T, class S = std::vector<T> >
- class stack
- {
- public:
- // Hide our reversed order.
- typedef typename S::reverse_iterator iterator;
- typedef typename S::const_reverse_iterator const_iterator;
-
- stack ()
- : seq_ ()
- {
- seq_.reserve (200);
- }
-
- stack (unsigned n)
- : seq_ (n)
- {}
-
- /// Random access.
- ///
- /// Index 0 returns the topmost element.
- T&
- operator[] (unsigned i)
- {
- return seq_[seq_.size () - 1 - i];
- }
-
- /// Random access.
- ///
- /// Index 0 returns the topmost element.
- const T&
- operator[] (unsigned i) const
- {
- return seq_[seq_.size () - 1 - i];
- }
-
- /// Steal the contents of \a t.
- ///
- /// Close to move-semantics.
- void
- push (T& t)
- {
- seq_.push_back (T());
- operator[](0).move (t);
- }
-
- void
- pop (unsigned n = 1)
- {
- for (; n; --n)
- seq_.pop_back ();
- }
-
- void
- clear ()
- {
- seq_.clear ();
- }
-
- typename S::size_type
- size () const
- {
- return seq_.size ();
- }
-
- const_iterator
- begin () const
- {
- return seq_.rbegin ();
- }
-
- const_iterator
- end () const
- {
- return seq_.rend ();
- }
-
- private:
- stack (const stack&);
- stack& operator= (const stack&);
- /// The wrapped container.
- S seq_;
- };
-
- /// Present a slice of the top of a stack.
- template <class T, class S = stack<T> >
- class slice
- {
- public:
- slice (const S& stack, unsigned range)
- : stack_ (stack)
- , range_ (range)
- {}
-
- const T&
- operator [] (unsigned i) const
- {
- return stack_[range_ - i];
- }
-
- private:
- const S& stack_;
- unsigned range_;
- };
-
-#line 14 "netconf_parser.yy" // stack.hh:131
-} } // isc::netconf
-#line 155 "stack.hh" // stack.hh:131
-
-#endif // !YY_NETCONF_STACK_HH_INCLUDED
+// Generated 201811172153
+// A Bison parser, made by GNU Bison 3.2.1.
+
+// Starting with Bison 3.2, this file is useless: the structure it
+// used to define is now defined with the parser itself.
+//
+// To get rid of this file:
+// 1. add 'require "3.2"' (or newer) to your grammar file
+// 2. remove references to this file from your build system.
-// Generated 201811151407
-// A Bison parser, made by GNU Bison 3.0.5.
+// Generated 201811172152
+// A Bison parser, made by GNU Bison 3.2.1.
// Locations for Bison parsers in C++
#ifndef YY_EVAL_LOCATION_HH_INCLUDED
# define YY_EVAL_LOCATION_HH_INCLUDED
-# include "position.hh"
+# include <algorithm> // std::max
+# include <iostream>
+# include <string>
-#line 14 "parser.yy" // location.cc:292
+# ifndef YY_NULLPTR
+# if defined __cplusplus
+# if 201103L <= __cplusplus
+# define YY_NULLPTR nullptr
+# else
+# define YY_NULLPTR 0
+# endif
+# else
+# define YY_NULLPTR ((void*)0)
+# endif
+# endif
+
+#line 14 "parser.yy" // location.cc:339
namespace isc { namespace eval {
-#line 46 "location.hh" // location.cc:292
- /// Abstract a location.
+#line 60 "location.hh" // location.cc:339
+ /// A point in a source file.
+ class position
+ {
+ public:
+ /// Construct a position.
+ explicit position (std::string* f = YY_NULLPTR,
+ unsigned l = 1u,
+ unsigned c = 1u)
+ : filename (f)
+ , line (l)
+ , column (c)
+ {}
+
+
+ /// Initialization.
+ void initialize (std::string* fn = YY_NULLPTR,
+ unsigned l = 1u,
+ unsigned c = 1u)
+ {
+ filename = fn;
+ line = l;
+ column = c;
+ }
+
+ /** \name Line and Column related manipulators
+ ** \{ */
+ /// (line related) Advance to the COUNT next lines.
+ void lines (int count = 1)
+ {
+ if (count)
+ {
+ column = 1u;
+ line = add_ (line, count, 1);
+ }
+ }
+
+ /// (column related) Advance to the COUNT next columns.
+ void columns (int count = 1)
+ {
+ column = add_ (column, count, 1);
+ }
+ /** \} */
+
+ /// File name to which this position refers.
+ std::string* filename;
+ /// Current line number.
+ unsigned line;
+ /// Current column number.
+ unsigned column;
+
+ private:
+ /// Compute max (min, lhs+rhs).
+ static unsigned add_ (unsigned lhs, int rhs, int min)
+ {
+ return static_cast<unsigned> (std::max (min,
+ static_cast<int> (lhs) + rhs));
+ }
+ };
+
+ /// Add \a width columns, in place.
+ inline position&
+ operator+= (position& res, int width)
+ {
+ res.columns (width);
+ return res;
+ }
+
+ /// Add \a width columns.
+ inline position
+ operator+ (position res, int width)
+ {
+ return res += width;
+ }
+
+ /// Subtract \a width columns, in place.
+ inline position&
+ operator-= (position& res, int width)
+ {
+ return res += -width;
+ }
+
+ /// Subtract \a width columns.
+ inline position
+ operator- (position res, int width)
+ {
+ return res -= width;
+ }
+
+ /// Compare two position objects.
+ inline bool
+ operator== (const position& pos1, const position& pos2)
+ {
+ return (pos1.line == pos2.line
+ && pos1.column == pos2.column
+ && (pos1.filename == pos2.filename
+ || (pos1.filename && pos2.filename
+ && *pos1.filename == *pos2.filename)));
+ }
+
+ /// Compare two position objects.
+ inline bool
+ operator!= (const position& pos1, const position& pos2)
+ {
+ return !(pos1 == pos2);
+ }
+
+ /** \brief Intercept output stream redirection.
+ ** \param ostr the destination output stream
+ ** \param pos a reference to the position to redirect
+ */
+ template <typename YYChar>
+ std::basic_ostream<YYChar>&
+ operator<< (std::basic_ostream<YYChar>& ostr, const position& pos)
+ {
+ if (pos.filename)
+ ostr << *pos.filename << ':';
+ return ostr << pos.line << '.' << pos.column;
+ }
+
+ /// Two points in a source file.
class location
{
public:
** Avoid duplicate information.
*/
template <typename YYChar>
- inline std::basic_ostream<YYChar>&
+ std::basic_ostream<YYChar>&
operator<< (std::basic_ostream<YYChar>& ostr, const location& loc)
{
unsigned end_col = 0 < loc.end.column ? loc.end.column - 1 : 0;
return ostr;
}
-#line 14 "parser.yy" // location.cc:292
+#line 14 "parser.yy" // location.cc:339
} } // isc::eval
-#line 189 "location.hh" // location.cc:292
+#line 322 "location.hh" // location.cc:339
#endif // !YY_EVAL_LOCATION_HH_INCLUDED
-// A Bison parser, made by GNU Bison 3.0.5.
+// A Bison parser, made by GNU Bison 3.2.1.
// Skeleton implementation for Bison LALR(1) parsers in C++
// This special exception was added by the Free Software Foundation in
// version 2.2 of Bison.
+// Undocumented macros, especially those whose name start with YY_,
+// are private implementation details. Do not rely on them.
+
+
// Take the name prefix into account.
#define yylex evallex
-// First part of user declarations.
-
-#line 39 "parser.cc" // lalr1.cc:406
-# ifndef YY_NULLPTR
-# if defined __cplusplus && 201103L <= __cplusplus
-# define YY_NULLPTR nullptr
-# else
-# define YY_NULLPTR 0
-# endif
-# endif
#include "parser.h"
-// User implementation prologue.
-#line 53 "parser.cc" // lalr1.cc:414
// Unqualified %code blocks.
-#line 33 "parser.yy" // lalr1.cc:415
+#line 33 "parser.yy" // lalr1.cc:438
# include "eval_context.h"
-#line 59 "parser.cc" // lalr1.cc:415
+#line 51 "parser.cc" // lalr1.cc:438
#ifndef YY_
# endif
#endif
+// Whether we are compiled with exception support.
+#ifndef YY_EXCEPTIONS
+# if defined __GNUC__ && !defined __EXCEPTIONS
+# define YY_EXCEPTIONS 0
+# else
+# define YY_EXCEPTIONS 1
+# endif
+#endif
+
#define YYRHSLOC(Rhs, K) ((Rhs)[K].location)
/* YYLLOC_DEFAULT -- Set CURRENT to span from RHS[1] to RHS[N].
If N is 0, then set CURRENT to the empty location which ends
#define YYERROR goto yyerrorlab
#define YYRECOVERING() (!!yyerrstatus_)
-#line 14 "parser.yy" // lalr1.cc:481
+#line 14 "parser.yy" // lalr1.cc:513
namespace isc { namespace eval {
-#line 145 "parser.cc" // lalr1.cc:481
+#line 146 "parser.cc" // lalr1.cc:513
/* Return YYSTR after stripping away unnecessary quotes and
backslashes, so that it's suitable for yyerror. The heuristic is
EvalParser::stack_symbol_type::stack_symbol_type ()
{}
- EvalParser::stack_symbol_type::stack_symbol_type (const stack_symbol_type& that)
- : super_type (that.state, that.location)
+ EvalParser::stack_symbol_type::stack_symbol_type (YY_RVREF (stack_symbol_type) that)
+ : super_type (YY_MOVE (that.state), YY_MOVE (that.location))
{
switch (that.type_get ())
{
case 62: // option_repr_type
- value.copy< TokenOption::RepresentationType > (that.value);
+ value.YY_MOVE_OR_COPY< TokenOption::RepresentationType > (YY_MOVE (that.value));
break;
case 66: // pkt4_field
- value.copy< TokenPkt4::FieldType > (that.value);
+ value.YY_MOVE_OR_COPY< TokenPkt4::FieldType > (YY_MOVE (that.value));
break;
case 67: // pkt6_field
- value.copy< TokenPkt6::FieldType > (that.value);
+ value.YY_MOVE_OR_COPY< TokenPkt6::FieldType > (YY_MOVE (that.value));
break;
case 64: // pkt_metadata
- value.copy< TokenPkt::MetadataType > (that.value);
+ value.YY_MOVE_OR_COPY< TokenPkt::MetadataType > (YY_MOVE (that.value));
break;
case 68: // relay6_field
- value.copy< TokenRelay6Field::FieldType > (that.value);
+ value.YY_MOVE_OR_COPY< TokenRelay6Field::FieldType > (YY_MOVE (that.value));
break;
case 63: // nest_level
- value.copy< int8_t > (that.value);
+ value.YY_MOVE_OR_COPY< int8_t > (YY_MOVE (that.value));
break;
case 50: // "constant string"
case 52: // "constant hexstring"
case 53: // "option name"
case 54: // "ip address"
- value.copy< std::string > (that.value);
+ value.YY_MOVE_OR_COPY< std::string > (YY_MOVE (that.value));
break;
case 61: // option_code
- value.copy< uint16_t > (that.value);
+ value.YY_MOVE_OR_COPY< uint16_t > (YY_MOVE (that.value));
break;
case 60: // integer_expr
case 65: // enterprise_id
- value.copy< uint32_t > (that.value);
+ value.YY_MOVE_OR_COPY< uint32_t > (YY_MOVE (that.value));
break;
default:
break;
}
+#if defined __cplusplus && 201103L <= __cplusplus
+ // that is emptied.
+ that.state = empty_state;
+#endif
}
- EvalParser::stack_symbol_type::stack_symbol_type (state_type s, symbol_type& that)
- : super_type (s, that.location)
+ EvalParser::stack_symbol_type::stack_symbol_type (state_type s, YY_MOVE_REF (symbol_type) that)
+ : super_type (s, YY_MOVE (that.location))
{
switch (that.type_get ())
{
case 62: // option_repr_type
- value.move< TokenOption::RepresentationType > (that.value);
+ value.move< TokenOption::RepresentationType > (YY_MOVE (that.value));
break;
case 66: // pkt4_field
- value.move< TokenPkt4::FieldType > (that.value);
+ value.move< TokenPkt4::FieldType > (YY_MOVE (that.value));
break;
case 67: // pkt6_field
- value.move< TokenPkt6::FieldType > (that.value);
+ value.move< TokenPkt6::FieldType > (YY_MOVE (that.value));
break;
case 64: // pkt_metadata
- value.move< TokenPkt::MetadataType > (that.value);
+ value.move< TokenPkt::MetadataType > (YY_MOVE (that.value));
break;
case 68: // relay6_field
- value.move< TokenRelay6Field::FieldType > (that.value);
+ value.move< TokenRelay6Field::FieldType > (YY_MOVE (that.value));
break;
case 63: // nest_level
- value.move< int8_t > (that.value);
+ value.move< int8_t > (YY_MOVE (that.value));
break;
case 50: // "constant string"
case 52: // "constant hexstring"
case 53: // "option name"
case 54: // "ip address"
- value.move< std::string > (that.value);
+ value.move< std::string > (YY_MOVE (that.value));
break;
case 61: // option_code
- value.move< uint16_t > (that.value);
+ value.move< uint16_t > (YY_MOVE (that.value));
break;
case 60: // integer_expr
case 65: // enterprise_id
- value.move< uint32_t > (that.value);
+ value.move< uint32_t > (YY_MOVE (that.value));
break;
default:
that.type = empty_symbol;
}
+#if !defined __cplusplus || __cplusplus < 201103L
EvalParser::stack_symbol_type&
- EvalParser::stack_symbol_type::operator= (const stack_symbol_type& that)
+ EvalParser::stack_symbol_type::operator= (stack_symbol_type& that)
{
state = that.state;
switch (that.type_get ())
{
case 62: // option_repr_type
- value.copy< TokenOption::RepresentationType > (that.value);
+ value.move< TokenOption::RepresentationType > (that.value);
break;
case 66: // pkt4_field
- value.copy< TokenPkt4::FieldType > (that.value);
+ value.move< TokenPkt4::FieldType > (that.value);
break;
case 67: // pkt6_field
- value.copy< TokenPkt6::FieldType > (that.value);
+ value.move< TokenPkt6::FieldType > (that.value);
break;
case 64: // pkt_metadata
- value.copy< TokenPkt::MetadataType > (that.value);
+ value.move< TokenPkt::MetadataType > (that.value);
break;
case 68: // relay6_field
- value.copy< TokenRelay6Field::FieldType > (that.value);
+ value.move< TokenRelay6Field::FieldType > (that.value);
break;
case 63: // nest_level
- value.copy< int8_t > (that.value);
+ value.move< int8_t > (that.value);
break;
case 50: // "constant string"
case 52: // "constant hexstring"
case 53: // "option name"
case 54: // "ip address"
- value.copy< std::string > (that.value);
+ value.move< std::string > (that.value);
break;
case 61: // option_code
- value.copy< uint16_t > (that.value);
+ value.move< uint16_t > (that.value);
break;
case 60: // integer_expr
case 65: // enterprise_id
- value.copy< uint32_t > (that.value);
+ value.move< uint32_t > (that.value);
break;
default:
}
location = that.location;
+ // that is emptied.
+ that.state = empty_state;
return *this;
}
-
+#endif
template <typename Base>
void
{
case 50: // "constant string"
-#line 111 "parser.yy" // lalr1.cc:635
+#line 111 "parser.yy" // lalr1.cc:672
{ yyoutput << yysym.value.template as< std::string > (); }
-#line 435 "parser.cc" // lalr1.cc:635
+#line 443 "parser.cc" // lalr1.cc:672
break;
case 51: // "integer"
-#line 111 "parser.yy" // lalr1.cc:635
+#line 111 "parser.yy" // lalr1.cc:672
{ yyoutput << yysym.value.template as< std::string > (); }
-#line 442 "parser.cc" // lalr1.cc:635
+#line 450 "parser.cc" // lalr1.cc:672
break;
case 52: // "constant hexstring"
-#line 111 "parser.yy" // lalr1.cc:635
+#line 111 "parser.yy" // lalr1.cc:672
{ yyoutput << yysym.value.template as< std::string > (); }
-#line 449 "parser.cc" // lalr1.cc:635
+#line 457 "parser.cc" // lalr1.cc:672
break;
case 53: // "option name"
-#line 111 "parser.yy" // lalr1.cc:635
+#line 111 "parser.yy" // lalr1.cc:672
{ yyoutput << yysym.value.template as< std::string > (); }
-#line 456 "parser.cc" // lalr1.cc:635
+#line 464 "parser.cc" // lalr1.cc:672
break;
case 54: // "ip address"
-#line 111 "parser.yy" // lalr1.cc:635
+#line 111 "parser.yy" // lalr1.cc:672
{ yyoutput << yysym.value.template as< std::string > (); }
-#line 463 "parser.cc" // lalr1.cc:635
+#line 471 "parser.cc" // lalr1.cc:672
break;
case 60: // integer_expr
-#line 111 "parser.yy" // lalr1.cc:635
+#line 111 "parser.yy" // lalr1.cc:672
{ yyoutput << yysym.value.template as< uint32_t > (); }
-#line 470 "parser.cc" // lalr1.cc:635
+#line 478 "parser.cc" // lalr1.cc:672
break;
case 61: // option_code
-#line 111 "parser.yy" // lalr1.cc:635
+#line 111 "parser.yy" // lalr1.cc:672
{ yyoutput << yysym.value.template as< uint16_t > (); }
-#line 477 "parser.cc" // lalr1.cc:635
+#line 485 "parser.cc" // lalr1.cc:672
break;
case 62: // option_repr_type
-#line 111 "parser.yy" // lalr1.cc:635
+#line 111 "parser.yy" // lalr1.cc:672
{ yyoutput << yysym.value.template as< TokenOption::RepresentationType > (); }
-#line 484 "parser.cc" // lalr1.cc:635
+#line 492 "parser.cc" // lalr1.cc:672
break;
case 63: // nest_level
-#line 111 "parser.yy" // lalr1.cc:635
+#line 111 "parser.yy" // lalr1.cc:672
{ yyoutput << yysym.value.template as< int8_t > (); }
-#line 491 "parser.cc" // lalr1.cc:635
+#line 499 "parser.cc" // lalr1.cc:672
break;
case 64: // pkt_metadata
-#line 111 "parser.yy" // lalr1.cc:635
+#line 111 "parser.yy" // lalr1.cc:672
{ yyoutput << yysym.value.template as< TokenPkt::MetadataType > (); }
-#line 498 "parser.cc" // lalr1.cc:635
+#line 506 "parser.cc" // lalr1.cc:672
break;
case 65: // enterprise_id
-#line 111 "parser.yy" // lalr1.cc:635
+#line 111 "parser.yy" // lalr1.cc:672
{ yyoutput << yysym.value.template as< uint32_t > (); }
-#line 505 "parser.cc" // lalr1.cc:635
+#line 513 "parser.cc" // lalr1.cc:672
break;
case 66: // pkt4_field
-#line 111 "parser.yy" // lalr1.cc:635
+#line 111 "parser.yy" // lalr1.cc:672
{ yyoutput << yysym.value.template as< TokenPkt4::FieldType > (); }
-#line 512 "parser.cc" // lalr1.cc:635
+#line 520 "parser.cc" // lalr1.cc:672
break;
case 67: // pkt6_field
-#line 111 "parser.yy" // lalr1.cc:635
+#line 111 "parser.yy" // lalr1.cc:672
{ yyoutput << yysym.value.template as< TokenPkt6::FieldType > (); }
-#line 519 "parser.cc" // lalr1.cc:635
+#line 527 "parser.cc" // lalr1.cc:672
break;
case 68: // relay6_field
-#line 111 "parser.yy" // lalr1.cc:635
+#line 111 "parser.yy" // lalr1.cc:672
{ yyoutput << yysym.value.template as< TokenRelay6Field::FieldType > (); }
-#line 526 "parser.cc" // lalr1.cc:635
+#line 534 "parser.cc" // lalr1.cc:672
break;
#endif
void
- EvalParser::yypush_ (const char* m, state_type s, symbol_type& sym)
+ EvalParser::yypush_ (const char* m, YY_MOVE_REF (stack_symbol_type) sym)
{
- stack_symbol_type t (s, sym);
- yypush_ (m, t);
+ if (m)
+ YY_SYMBOL_PRINT (m, sym);
+ yystack_.push (YY_MOVE (sym));
}
void
- EvalParser::yypush_ (const char* m, stack_symbol_type& s)
+ EvalParser::yypush_ (const char* m, state_type s, YY_MOVE_REF (symbol_type) sym)
{
- if (m)
- YY_SYMBOL_PRINT (m, s);
- yystack_.push (s);
+#if defined __cplusplus && 201103L <= __cplusplus
+ yypush_ (m, stack_symbol_type (s, std::move (sym)));
+#else
+ stack_symbol_type ss (s, sym);
+ yypush_ (m, ss);
+#endif
}
void
- EvalParser::yypop_ (unsigned n)
+ EvalParser::yypop_ (int n)
{
yystack_.pop (n);
}
return yyvalue == yytable_ninf_;
}
+ int
+ EvalParser::operator() ()
+ {
+ return parse ();
+ }
+
int
EvalParser::parse ()
{
/// The return value of parse ().
int yyresult;
- // FIXME: This shoud be completely indented. It is not yet to
- // avoid gratuitous conflicts when merging into the master branch.
+#if YY_EXCEPTIONS
try
+#endif // YY_EXCEPTIONS
{
YYCDEBUG << "Starting parse\n";
location values to have been already stored, initialize these
stacks with a primary value. */
yystack_.clear ();
- yypush_ (YY_NULLPTR, 0, yyla);
+ yypush_ (YY_NULLPTR, 0, YY_MOVE (yyla));
// A new symbol was pushed on the stack.
yynewstate:
// Backup.
yybackup:
-
// Try to take a decision without lookahead.
yyn = yypact_[yystack_[0].state];
if (yy_pact_value_is_default_ (yyn))
if (yyla.empty ())
{
YYCDEBUG << "Reading a token: ";
+#if YY_EXCEPTIONS
try
+#endif // YY_EXCEPTIONS
{
symbol_type yylookahead (yylex (ctx));
yyla.move (yylookahead);
}
+#if YY_EXCEPTIONS
catch (const syntax_error& yyexc)
{
error (yyexc);
goto yyerrlab1;
}
+#endif // YY_EXCEPTIONS
}
YY_SYMBOL_PRINT ("Next token is", yyla);
--yyerrstatus_;
// Shift the lookahead token.
- yypush_ ("Shifting", yyn, yyla);
+ yypush_ ("Shifting", yyn, YY_MOVE (yyla));
goto yynewstate;
/*-----------------------------------------------------------.
switch (yyr1_[yyn])
{
case 62: // option_repr_type
- yylhs.value.build< TokenOption::RepresentationType > ();
+ yylhs.value.emplace< TokenOption::RepresentationType > ();
break;
case 66: // pkt4_field
- yylhs.value.build< TokenPkt4::FieldType > ();
+ yylhs.value.emplace< TokenPkt4::FieldType > ();
break;
case 67: // pkt6_field
- yylhs.value.build< TokenPkt6::FieldType > ();
+ yylhs.value.emplace< TokenPkt6::FieldType > ();
break;
case 64: // pkt_metadata
- yylhs.value.build< TokenPkt::MetadataType > ();
+ yylhs.value.emplace< TokenPkt::MetadataType > ();
break;
case 68: // relay6_field
- yylhs.value.build< TokenRelay6Field::FieldType > ();
+ yylhs.value.emplace< TokenRelay6Field::FieldType > ();
break;
case 63: // nest_level
- yylhs.value.build< int8_t > ();
+ yylhs.value.emplace< int8_t > ();
break;
case 50: // "constant string"
case 52: // "constant hexstring"
case 53: // "option name"
case 54: // "ip address"
- yylhs.value.build< std::string > ();
+ yylhs.value.emplace< std::string > ();
break;
case 61: // option_code
- yylhs.value.build< uint16_t > ();
+ yylhs.value.emplace< uint16_t > ();
break;
case 60: // integer_expr
case 65: // enterprise_id
- yylhs.value.build< uint32_t > ();
+ yylhs.value.emplace< uint32_t > ();
break;
default:
// Perform the reduction.
YY_REDUCE_PRINT (yyn);
+#if YY_EXCEPTIONS
try
+#endif // YY_EXCEPTIONS
{
switch (yyn)
{
case 6:
-#line 131 "parser.yy" // lalr1.cc:856
+#line 131 "parser.yy" // lalr1.cc:907
{
TokenPtr neg(new TokenNot());
ctx.expression.push_back(neg);
}
-#line 788 "parser.cc" // lalr1.cc:856
+#line 811 "parser.cc" // lalr1.cc:907
break;
case 7:
-#line 136 "parser.yy" // lalr1.cc:856
+#line 136 "parser.yy" // lalr1.cc:907
{
TokenPtr neg(new TokenAnd());
ctx.expression.push_back(neg);
}
-#line 797 "parser.cc" // lalr1.cc:856
+#line 820 "parser.cc" // lalr1.cc:907
break;
case 8:
-#line 141 "parser.yy" // lalr1.cc:856
+#line 141 "parser.yy" // lalr1.cc:907
{
TokenPtr neg(new TokenOr());
ctx.expression.push_back(neg);
}
-#line 806 "parser.cc" // lalr1.cc:856
+#line 829 "parser.cc" // lalr1.cc:907
break;
case 9:
-#line 146 "parser.yy" // lalr1.cc:856
+#line 146 "parser.yy" // lalr1.cc:907
{
TokenPtr eq(new TokenEqual());
ctx.expression.push_back(eq);
}
-#line 815 "parser.cc" // lalr1.cc:856
+#line 838 "parser.cc" // lalr1.cc:907
break;
case 10:
-#line 151 "parser.yy" // lalr1.cc:856
+#line 151 "parser.yy" // lalr1.cc:907
{
TokenPtr opt(new TokenOption(yystack_[3].value.as< uint16_t > (), TokenOption::EXISTS));
ctx.expression.push_back(opt);
}
-#line 824 "parser.cc" // lalr1.cc:856
+#line 847 "parser.cc" // lalr1.cc:907
break;
case 11:
-#line 156 "parser.yy" // lalr1.cc:856
+#line 156 "parser.yy" // lalr1.cc:907
{
switch (ctx.getUniverse()) {
case Option::V4:
error(yystack_[5].location, "relay4 can only be used in DHCPv4.");
}
}
-#line 848 "parser.cc" // lalr1.cc:856
+#line 871 "parser.cc" // lalr1.cc:907
break;
case 12:
-#line 176 "parser.yy" // lalr1.cc:856
+#line 176 "parser.yy" // lalr1.cc:907
{
switch (ctx.getUniverse()) {
case Option::V6:
error(yystack_[10].location, "relay6 can only be used in DHCPv6.");
}
}
-#line 866 "parser.cc" // lalr1.cc:856
+#line 889 "parser.cc" // lalr1.cc:907
break;
case 13:
-#line 190 "parser.yy" // lalr1.cc:856
+#line 190 "parser.yy" // lalr1.cc:907
{
// Expression: vendor-class[1234].exists
//
TokenPtr exist(new TokenVendorClass(ctx.getUniverse(), yystack_[3].value.as< uint32_t > (), TokenOption::EXISTS));
ctx.expression.push_back(exist);
}
-#line 879 "parser.cc" // lalr1.cc:856
+#line 902 "parser.cc" // lalr1.cc:907
break;
case 14:
-#line 199 "parser.yy" // lalr1.cc:856
+#line 199 "parser.yy" // lalr1.cc:907
{
// Expression: vendor[1234].exists
//
TokenPtr exist(new TokenVendor(ctx.getUniverse(), yystack_[3].value.as< uint32_t > (), TokenOption::EXISTS));
ctx.expression.push_back(exist);
}
-#line 892 "parser.cc" // lalr1.cc:856
+#line 915 "parser.cc" // lalr1.cc:907
break;
case 15:
-#line 208 "parser.yy" // lalr1.cc:856
+#line 208 "parser.yy" // lalr1.cc:907
{
// Expression vendor[1234].option[123].exists
//
TokenPtr exist(new TokenVendor(ctx.getUniverse(), yystack_[8].value.as< uint32_t > (), TokenOption::EXISTS, yystack_[3].value.as< uint16_t > ()));
ctx.expression.push_back(exist);
}
-#line 906 "parser.cc" // lalr1.cc:856
+#line 929 "parser.cc" // lalr1.cc:907
break;
case 16:
-#line 218 "parser.yy" // lalr1.cc:856
+#line 218 "parser.yy" // lalr1.cc:907
{
// Expression member('foo')
//
TokenPtr member(new TokenMember(cc));
ctx.expression.push_back(member);
}
-#line 925 "parser.cc" // lalr1.cc:856
+#line 948 "parser.cc" // lalr1.cc:907
break;
case 17:
-#line 235 "parser.yy" // lalr1.cc:856
+#line 235 "parser.yy" // lalr1.cc:907
{
TokenPtr str(new TokenString(yystack_[0].value.as< std::string > ()));
ctx.expression.push_back(str);
}
-#line 934 "parser.cc" // lalr1.cc:856
+#line 957 "parser.cc" // lalr1.cc:907
break;
case 18:
-#line 240 "parser.yy" // lalr1.cc:856
+#line 240 "parser.yy" // lalr1.cc:907
{
TokenPtr hex(new TokenHexString(yystack_[0].value.as< std::string > ()));
ctx.expression.push_back(hex);
}
-#line 943 "parser.cc" // lalr1.cc:856
+#line 966 "parser.cc" // lalr1.cc:907
break;
case 19:
-#line 245 "parser.yy" // lalr1.cc:856
+#line 245 "parser.yy" // lalr1.cc:907
{
TokenPtr ip(new TokenIpAddress(yystack_[0].value.as< std::string > ()));
ctx.expression.push_back(ip);
}
-#line 952 "parser.cc" // lalr1.cc:856
+#line 975 "parser.cc" // lalr1.cc:907
break;
case 20:
-#line 250 "parser.yy" // lalr1.cc:856
+#line 250 "parser.yy" // lalr1.cc:907
{
TokenPtr opt(new TokenOption(yystack_[3].value.as< uint16_t > (), yystack_[0].value.as< TokenOption::RepresentationType > ()));
ctx.expression.push_back(opt);
}
-#line 961 "parser.cc" // lalr1.cc:856
+#line 984 "parser.cc" // lalr1.cc:907
break;
case 21:
-#line 255 "parser.yy" // lalr1.cc:856
+#line 255 "parser.yy" // lalr1.cc:907
{
switch (ctx.getUniverse()) {
case Option::V4:
error(yystack_[5].location, "relay4 can only be used in DHCPv4.");
}
}
-#line 985 "parser.cc" // lalr1.cc:856
+#line 1008 "parser.cc" // lalr1.cc:907
break;
case 22:
-#line 276 "parser.yy" // lalr1.cc:856
+#line 276 "parser.yy" // lalr1.cc:907
{
switch (ctx.getUniverse()) {
case Option::V6:
error(yystack_[10].location, "relay6 can only be used in DHCPv6.");
}
}
-#line 1003 "parser.cc" // lalr1.cc:856
+#line 1026 "parser.cc" // lalr1.cc:907
break;
case 23:
-#line 291 "parser.yy" // lalr1.cc:856
+#line 291 "parser.yy" // lalr1.cc:907
{
TokenPtr pkt_metadata(new TokenPkt(yystack_[0].value.as< TokenPkt::MetadataType > ()));
ctx.expression.push_back(pkt_metadata);
}
-#line 1012 "parser.cc" // lalr1.cc:856
+#line 1035 "parser.cc" // lalr1.cc:907
break;
case 24:
-#line 296 "parser.yy" // lalr1.cc:856
+#line 296 "parser.yy" // lalr1.cc:907
{
switch (ctx.getUniverse()) {
case Option::V4:
error(yystack_[2].location, "pkt4 can only be used in DHCPv4.");
}
}
-#line 1030 "parser.cc" // lalr1.cc:856
+#line 1053 "parser.cc" // lalr1.cc:907
break;
case 25:
-#line 310 "parser.yy" // lalr1.cc:856
+#line 310 "parser.yy" // lalr1.cc:907
{
switch (ctx.getUniverse()) {
case Option::V6:
error(yystack_[2].location, "pkt6 can only be used in DHCPv6.");
}
}
-#line 1048 "parser.cc" // lalr1.cc:856
+#line 1071 "parser.cc" // lalr1.cc:907
break;
case 26:
-#line 324 "parser.yy" // lalr1.cc:856
+#line 324 "parser.yy" // lalr1.cc:907
{
switch (ctx.getUniverse()) {
case Option::V6:
error(yystack_[5].location, "relay6 can only be used in DHCPv6.");
}
}
-#line 1066 "parser.cc" // lalr1.cc:856
+#line 1089 "parser.cc" // lalr1.cc:907
break;
case 27:
-#line 339 "parser.yy" // lalr1.cc:856
+#line 339 "parser.yy" // lalr1.cc:907
{
TokenPtr sub(new TokenSubstring());
ctx.expression.push_back(sub);
}
-#line 1075 "parser.cc" // lalr1.cc:856
+#line 1098 "parser.cc" // lalr1.cc:907
break;
case 28:
-#line 344 "parser.yy" // lalr1.cc:856
+#line 344 "parser.yy" // lalr1.cc:907
{
TokenPtr conc(new TokenConcat());
ctx.expression.push_back(conc);
}
-#line 1084 "parser.cc" // lalr1.cc:856
+#line 1107 "parser.cc" // lalr1.cc:907
break;
case 29:
-#line 349 "parser.yy" // lalr1.cc:856
+#line 349 "parser.yy" // lalr1.cc:907
{
TokenPtr cond(new TokenIfElse());
ctx.expression.push_back(cond);
}
-#line 1093 "parser.cc" // lalr1.cc:856
+#line 1116 "parser.cc" // lalr1.cc:907
break;
case 30:
-#line 354 "parser.yy" // lalr1.cc:856
+#line 354 "parser.yy" // lalr1.cc:907
{
TokenPtr tohex(new TokenToHexString());
ctx.expression.push_back(tohex);
}
-#line 1102 "parser.cc" // lalr1.cc:856
+#line 1125 "parser.cc" // lalr1.cc:907
break;
case 31:
-#line 359 "parser.yy" // lalr1.cc:856
+#line 359 "parser.yy" // lalr1.cc:907
{
// expression: vendor.enterprise
//
TokenPtr vendor(new TokenVendor(ctx.getUniverse(), 0, TokenVendor::ENTERPRISE_ID));
ctx.expression.push_back(vendor);
}
-#line 1115 "parser.cc" // lalr1.cc:856
+#line 1138 "parser.cc" // lalr1.cc:907
break;
case 32:
-#line 368 "parser.yy" // lalr1.cc:856
+#line 368 "parser.yy" // lalr1.cc:907
{
// expression: vendor-class.enterprise
//
TokenVendor::ENTERPRISE_ID));
ctx.expression.push_back(vendor);
}
-#line 1129 "parser.cc" // lalr1.cc:856
+#line 1152 "parser.cc" // lalr1.cc:907
break;
case 33:
-#line 378 "parser.yy" // lalr1.cc:856
+#line 378 "parser.yy" // lalr1.cc:907
{
// This token will search for vendor option with
// specified enterprise-id. If found, will search
TokenPtr opt(new TokenVendor(ctx.getUniverse(), yystack_[8].value.as< uint32_t > (), yystack_[0].value.as< TokenOption::RepresentationType > (), yystack_[3].value.as< uint16_t > ()));
ctx.expression.push_back(opt);
}
-#line 1142 "parser.cc" // lalr1.cc:856
+#line 1165 "parser.cc" // lalr1.cc:907
break;
case 34:
-#line 387 "parser.yy" // lalr1.cc:856
+#line 387 "parser.yy" // lalr1.cc:907
{
// expression: vendor-class[1234].data
//
TokenVendor::DATA, 0));
ctx.expression.push_back(vendor_class);
}
-#line 1159 "parser.cc" // lalr1.cc:856
+#line 1182 "parser.cc" // lalr1.cc:907
break;
case 35:
-#line 400 "parser.yy" // lalr1.cc:856
+#line 400 "parser.yy" // lalr1.cc:907
{
// expression: vendor-class[1234].data[5]
//
TokenVendor::DATA, index));
ctx.expression.push_back(vendor_class);
}
-#line 1176 "parser.cc" // lalr1.cc:856
+#line 1199 "parser.cc" // lalr1.cc:907
break;
case 36:
-#line 413 "parser.yy" // lalr1.cc:856
+#line 413 "parser.yy" // lalr1.cc:907
{
TokenPtr integer(new TokenInteger(yystack_[0].value.as< uint32_t > ()));
ctx.expression.push_back(integer);
}
-#line 1185 "parser.cc" // lalr1.cc:856
+#line 1208 "parser.cc" // lalr1.cc:907
break;
case 37:
-#line 420 "parser.yy" // lalr1.cc:856
+#line 420 "parser.yy" // lalr1.cc:907
{
yylhs.value.as< uint32_t > () = ctx.convertUint32(yystack_[0].value.as< std::string > (), yystack_[0].location);
}
-#line 1193 "parser.cc" // lalr1.cc:856
+#line 1216 "parser.cc" // lalr1.cc:907
break;
case 38:
-#line 426 "parser.yy" // lalr1.cc:856
+#line 426 "parser.yy" // lalr1.cc:907
{
yylhs.value.as< uint16_t > () = ctx.convertOptionCode(yystack_[0].value.as< std::string > (), yystack_[0].location);
}
-#line 1201 "parser.cc" // lalr1.cc:856
+#line 1224 "parser.cc" // lalr1.cc:907
break;
case 39:
-#line 430 "parser.yy" // lalr1.cc:856
+#line 430 "parser.yy" // lalr1.cc:907
{
yylhs.value.as< uint16_t > () = ctx.convertOptionName(yystack_[0].value.as< std::string > (), yystack_[0].location);
}
-#line 1209 "parser.cc" // lalr1.cc:856
+#line 1232 "parser.cc" // lalr1.cc:907
break;
case 40:
-#line 436 "parser.yy" // lalr1.cc:856
+#line 436 "parser.yy" // lalr1.cc:907
{
yylhs.value.as< TokenOption::RepresentationType > () = TokenOption::TEXTUAL;
}
-#line 1217 "parser.cc" // lalr1.cc:856
+#line 1240 "parser.cc" // lalr1.cc:907
break;
case 41:
-#line 440 "parser.yy" // lalr1.cc:856
+#line 440 "parser.yy" // lalr1.cc:907
{
yylhs.value.as< TokenOption::RepresentationType > () = TokenOption::HEXADECIMAL;
}
-#line 1225 "parser.cc" // lalr1.cc:856
+#line 1248 "parser.cc" // lalr1.cc:907
break;
case 42:
-#line 446 "parser.yy" // lalr1.cc:856
+#line 446 "parser.yy" // lalr1.cc:907
{
yylhs.value.as< int8_t > () = ctx.convertNestLevelNumber(yystack_[0].value.as< std::string > (), yystack_[0].location);
}
-#line 1233 "parser.cc" // lalr1.cc:856
+#line 1256 "parser.cc" // lalr1.cc:907
break;
case 43:
-#line 455 "parser.yy" // lalr1.cc:856
+#line 455 "parser.yy" // lalr1.cc:907
{
yylhs.value.as< TokenPkt::MetadataType > () = TokenPkt::IFACE;
}
-#line 1241 "parser.cc" // lalr1.cc:856
+#line 1264 "parser.cc" // lalr1.cc:907
break;
case 44:
-#line 459 "parser.yy" // lalr1.cc:856
+#line 459 "parser.yy" // lalr1.cc:907
{
yylhs.value.as< TokenPkt::MetadataType > () = TokenPkt::SRC;
}
-#line 1249 "parser.cc" // lalr1.cc:856
+#line 1272 "parser.cc" // lalr1.cc:907
break;
case 45:
-#line 463 "parser.yy" // lalr1.cc:856
+#line 463 "parser.yy" // lalr1.cc:907
{
yylhs.value.as< TokenPkt::MetadataType > () = TokenPkt::DST;
}
-#line 1257 "parser.cc" // lalr1.cc:856
+#line 1280 "parser.cc" // lalr1.cc:907
break;
case 46:
-#line 467 "parser.yy" // lalr1.cc:856
+#line 467 "parser.yy" // lalr1.cc:907
{
yylhs.value.as< TokenPkt::MetadataType > () = TokenPkt::LEN;
}
-#line 1265 "parser.cc" // lalr1.cc:856
+#line 1288 "parser.cc" // lalr1.cc:907
break;
case 47:
-#line 473 "parser.yy" // lalr1.cc:856
+#line 473 "parser.yy" // lalr1.cc:907
{
yylhs.value.as< uint32_t > () = ctx.convertUint32(yystack_[0].value.as< std::string > (), yystack_[0].location);
}
-#line 1273 "parser.cc" // lalr1.cc:856
+#line 1296 "parser.cc" // lalr1.cc:907
break;
case 48:
-#line 477 "parser.yy" // lalr1.cc:856
+#line 477 "parser.yy" // lalr1.cc:907
{
yylhs.value.as< uint32_t > () = 0;
}
-#line 1281 "parser.cc" // lalr1.cc:856
+#line 1304 "parser.cc" // lalr1.cc:907
break;
case 49:
-#line 483 "parser.yy" // lalr1.cc:856
+#line 483 "parser.yy" // lalr1.cc:907
{
yylhs.value.as< TokenPkt4::FieldType > () = TokenPkt4::CHADDR;
}
-#line 1289 "parser.cc" // lalr1.cc:856
+#line 1312 "parser.cc" // lalr1.cc:907
break;
case 50:
-#line 487 "parser.yy" // lalr1.cc:856
+#line 487 "parser.yy" // lalr1.cc:907
{
yylhs.value.as< TokenPkt4::FieldType > () = TokenPkt4::HLEN;
}
-#line 1297 "parser.cc" // lalr1.cc:856
+#line 1320 "parser.cc" // lalr1.cc:907
break;
case 51:
-#line 491 "parser.yy" // lalr1.cc:856
+#line 491 "parser.yy" // lalr1.cc:907
{
yylhs.value.as< TokenPkt4::FieldType > () = TokenPkt4::HTYPE;
}
-#line 1305 "parser.cc" // lalr1.cc:856
+#line 1328 "parser.cc" // lalr1.cc:907
break;
case 52:
-#line 495 "parser.yy" // lalr1.cc:856
+#line 495 "parser.yy" // lalr1.cc:907
{
yylhs.value.as< TokenPkt4::FieldType > () = TokenPkt4::CIADDR;
}
-#line 1313 "parser.cc" // lalr1.cc:856
+#line 1336 "parser.cc" // lalr1.cc:907
break;
case 53:
-#line 499 "parser.yy" // lalr1.cc:856
+#line 499 "parser.yy" // lalr1.cc:907
{
yylhs.value.as< TokenPkt4::FieldType > () = TokenPkt4::GIADDR;
}
-#line 1321 "parser.cc" // lalr1.cc:856
+#line 1344 "parser.cc" // lalr1.cc:907
break;
case 54:
-#line 503 "parser.yy" // lalr1.cc:856
+#line 503 "parser.yy" // lalr1.cc:907
{
yylhs.value.as< TokenPkt4::FieldType > () = TokenPkt4::YIADDR;
}
-#line 1329 "parser.cc" // lalr1.cc:856
+#line 1352 "parser.cc" // lalr1.cc:907
break;
case 55:
-#line 507 "parser.yy" // lalr1.cc:856
+#line 507 "parser.yy" // lalr1.cc:907
{
yylhs.value.as< TokenPkt4::FieldType > () = TokenPkt4::SIADDR;
}
-#line 1337 "parser.cc" // lalr1.cc:856
+#line 1360 "parser.cc" // lalr1.cc:907
break;
case 56:
-#line 511 "parser.yy" // lalr1.cc:856
+#line 511 "parser.yy" // lalr1.cc:907
{
yylhs.value.as< TokenPkt4::FieldType > () = TokenPkt4::MSGTYPE;
}
-#line 1345 "parser.cc" // lalr1.cc:856
+#line 1368 "parser.cc" // lalr1.cc:907
break;
case 57:
-#line 515 "parser.yy" // lalr1.cc:856
+#line 515 "parser.yy" // lalr1.cc:907
{
yylhs.value.as< TokenPkt4::FieldType > () = TokenPkt4::TRANSID;
}
-#line 1353 "parser.cc" // lalr1.cc:856
+#line 1376 "parser.cc" // lalr1.cc:907
break;
case 58:
-#line 521 "parser.yy" // lalr1.cc:856
+#line 521 "parser.yy" // lalr1.cc:907
{
yylhs.value.as< TokenPkt6::FieldType > () = TokenPkt6::MSGTYPE;
}
-#line 1361 "parser.cc" // lalr1.cc:856
+#line 1384 "parser.cc" // lalr1.cc:907
break;
case 59:
-#line 525 "parser.yy" // lalr1.cc:856
+#line 525 "parser.yy" // lalr1.cc:907
{
yylhs.value.as< TokenPkt6::FieldType > () = TokenPkt6::TRANSID;
}
-#line 1369 "parser.cc" // lalr1.cc:856
+#line 1392 "parser.cc" // lalr1.cc:907
break;
case 60:
-#line 531 "parser.yy" // lalr1.cc:856
+#line 531 "parser.yy" // lalr1.cc:907
{
yylhs.value.as< TokenRelay6Field::FieldType > () = TokenRelay6Field::PEERADDR;
}
-#line 1377 "parser.cc" // lalr1.cc:856
+#line 1400 "parser.cc" // lalr1.cc:907
break;
case 61:
-#line 535 "parser.yy" // lalr1.cc:856
+#line 535 "parser.yy" // lalr1.cc:907
{
yylhs.value.as< TokenRelay6Field::FieldType > () = TokenRelay6Field::LINKADDR;
}
-#line 1385 "parser.cc" // lalr1.cc:856
+#line 1408 "parser.cc" // lalr1.cc:907
break;
case 62:
-#line 541 "parser.yy" // lalr1.cc:856
+#line 541 "parser.yy" // lalr1.cc:907
{
TokenPtr str(new TokenString(yystack_[0].value.as< std::string > ()));
ctx.expression.push_back(str);
}
-#line 1394 "parser.cc" // lalr1.cc:856
+#line 1417 "parser.cc" // lalr1.cc:907
break;
case 63:
-#line 548 "parser.yy" // lalr1.cc:856
+#line 548 "parser.yy" // lalr1.cc:907
{
TokenPtr str(new TokenString(yystack_[0].value.as< std::string > ()));
ctx.expression.push_back(str);
}
-#line 1403 "parser.cc" // lalr1.cc:856
+#line 1426 "parser.cc" // lalr1.cc:907
break;
case 64:
-#line 553 "parser.yy" // lalr1.cc:856
+#line 553 "parser.yy" // lalr1.cc:907
{
TokenPtr str(new TokenString("all"));
ctx.expression.push_back(str);
}
-#line 1412 "parser.cc" // lalr1.cc:856
+#line 1435 "parser.cc" // lalr1.cc:907
break;
-#line 1416 "parser.cc" // lalr1.cc:856
+#line 1439 "parser.cc" // lalr1.cc:907
default:
break;
}
}
+#if YY_EXCEPTIONS
catch (const syntax_error& yyexc)
{
error (yyexc);
YYERROR;
}
+#endif // YY_EXCEPTIONS
YY_SYMBOL_PRINT ("-> $$ =", yylhs);
yypop_ (yylen);
yylen = 0;
YY_STACK_PRINT ();
// Shift the result of the reduction.
- yypush_ (YY_NULLPTR, yylhs);
+ yypush_ (YY_NULLPTR, YY_MOVE (yylhs));
}
goto yynewstate;
// Shift the error token.
error_token.state = yyn;
- yypush_ ("Shifting", error_token);
+ yypush_ ("Shifting", YY_MOVE (error_token));
}
goto yynewstate;
return yyresult;
}
+#if YY_EXCEPTIONS
catch (...)
{
YYCDEBUG << "Exception caught: cleaning lookahead and stack\n";
// Do not try to display the values of the reclaimed symbols,
- // as their printer might throw an exception.
+ // as their printers might throw an exception.
if (!yyla.empty ())
yy_destroy_ (YY_NULLPTR, yyla);
}
throw;
}
+#endif // YY_EXCEPTIONS
}
void
const signed char EvalParser::yytable_ninf_ = -1;
- const short int
+ const short
EvalParser::yypact_[] =
{
-14, 27, 76, 17, 27, 27, 37, 41, 53, 39,
15, 33
};
- const short int
+ const short
EvalParser::yypgoto_[] =
{
-118, -118, -118, 3, -2, -118, -36, -117, 138, -118,
-34, -118, -118, -118, -118, -118
};
- const short int
+ const short
EvalParser::yydefgoto_[] =
{
-1, 3, 23, 24, 25, 26, 62, 136, 65, 71,
};
#if EVALDEBUG
- const unsigned short int
+ const unsigned short
EvalParser::yyrline_[] =
{
0, 120, 120, 121, 126, 129, 130, 135, 140, 145,
#endif // EVALDEBUG
-#line 14 "parser.yy" // lalr1.cc:1163
+#line 14 "parser.yy" // lalr1.cc:1218
} } // isc::eval
-#line 1903 "parser.cc" // lalr1.cc:1163
-#line 559 "parser.yy" // lalr1.cc:1164
+#line 1930 "parser.cc" // lalr1.cc:1218
+#line 559 "parser.yy" // lalr1.cc:1219
void
isc::eval::EvalParser::error(const location_type& loc,
-// A Bison parser, made by GNU Bison 3.0.5.
+// A Bison parser, made by GNU Bison 3.2.1.
// Skeleton interface for Bison LALR(1) parsers in C++
// This special exception was added by the Free Software Foundation in
// version 2.2 of Bison.
+
/**
** \file parser.h
** Define the isc::eval::parser class.
// C++ LALR(1) parser skeleton written by Akim Demaille.
+// Undocumented macros, especially those whose name start with YY_,
+// are private implementation details. Do not rely on them.
+
#ifndef YY_EVAL_PARSER_H_INCLUDED
# define YY_EVAL_PARSER_H_INCLUDED
// // "%code requires" blocks.
-#line 17 "parser.yy" // lalr1.cc:379
+#line 17 "parser.yy" // lalr1.cc:404
#include <string>
#include <eval/token.h>
using namespace isc::dhcp;
using namespace isc::eval;
-#line 55 "parser.h" // lalr1.cc:379
+#line 59 "parser.h" // lalr1.cc:404
# include <cassert>
# include <cstdlib> // std::abort
# include <stdexcept>
# include <string>
# include <vector>
-# include "stack.hh"
+
+// Support move semantics when possible.
+#if defined __cplusplus && 201103L <= __cplusplus
+# define YY_MOVE std::move
+# define YY_MOVE_OR_COPY move
+# define YY_MOVE_REF(Type) Type&&
+# define YY_RVREF(Type) Type&&
+# define YY_COPY(Type) Type
+#else
+# define YY_MOVE
+# define YY_MOVE_OR_COPY copy
+# define YY_MOVE_REF(Type) Type&
+# define YY_RVREF(Type) const Type&
+# define YY_COPY(Type) const Type&
+#endif
# include "location.hh"
#include <typeinfo>
#ifndef YYASSERT
# define YY_ATTRIBUTE_UNUSED YY_ATTRIBUTE ((__unused__))
#endif
-#if !defined _Noreturn \
- && (!defined __STDC_VERSION__ || __STDC_VERSION__ < 201112)
-# if defined _MSC_VER && 1200 <= _MSC_VER
-# define _Noreturn __declspec (noreturn)
-# else
-# define _Noreturn YY_ATTRIBUTE ((__noreturn__))
-# endif
-#endif
-
/* Suppress unused-variable warnings by "using" E. */
#if ! defined lint || defined __GNUC__
# define YYUSE(E) ((void) (E))
# define YYUSE(E) /* empty */
#endif
-#if defined __GNUC__ && 407 <= __GNUC__ * 100 + __GNUC_MINOR__
+#if defined __GNUC__ && ! defined __ICC && 407 <= __GNUC__ * 100 + __GNUC_MINOR__
/* Suppress an incorrect diagnostic about yylval being uninitialized. */
# define YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN \
_Pragma ("GCC diagnostic push") \
# define YY_INITIAL_VALUE(Value) /* Nothing. */
#endif
+# ifndef YY_NULLPTR
+# if defined __cplusplus
+# if 201103L <= __cplusplus
+# define YY_NULLPTR nullptr
+# else
+# define YY_NULLPTR 0
+# endif
+# else
+# define YY_NULLPTR ((void*)0)
+# endif
+# endif
+
/* Debug traces. */
#ifndef EVALDEBUG
# if defined YYDEBUG
# endif /* ! defined YYDEBUG */
#endif /* ! defined EVALDEBUG */
-#line 14 "parser.yy" // lalr1.cc:379
+#line 14 "parser.yy" // lalr1.cc:404
namespace isc { namespace eval {
-#line 140 "parser.h" // lalr1.cc:379
+#line 161 "parser.h" // lalr1.cc:404
+
+ /// A stack with random access from its top.
+ template <typename T, typename S = std::vector<T> >
+ class stack
+ {
+ public:
+ // Hide our reversed order.
+ typedef typename S::reverse_iterator iterator;
+ typedef typename S::const_reverse_iterator const_iterator;
+ typedef typename S::size_type size_type;
+
+ stack (size_type n = 200)
+ : seq_ (n)
+ {}
+
+ /// Random access.
+ ///
+ /// Index 0 returns the topmost element.
+ T&
+ operator[] (size_type i)
+ {
+ return seq_[size () - 1 - i];
+ }
+
+ /// Random access.
+ ///
+ /// Index 0 returns the topmost element.
+ T&
+ operator[] (int i)
+ {
+ return operator[] (size_type (i));
+ }
+
+ /// Random access.
+ ///
+ /// Index 0 returns the topmost element.
+ const T&
+ operator[] (size_type i) const
+ {
+ return seq_[size () - 1 - i];
+ }
+
+ /// Random access.
+ ///
+ /// Index 0 returns the topmost element.
+ const T&
+ operator[] (int i) const
+ {
+ return operator[] (size_type (i));
+ }
+
+ /// Steal the contents of \a t.
+ ///
+ /// Close to move-semantics.
+ void
+ push (YY_MOVE_REF (T) t)
+ {
+ seq_.push_back (T ());
+ operator[](0).move (t);
+ }
+
+ void
+ pop (int n = 1)
+ {
+ for (; 0 < n; --n)
+ seq_.pop_back ();
+ }
+
+ void
+ clear ()
+ {
+ seq_.clear ();
+ }
+
+ size_type
+ size () const
+ {
+ return seq_.size ();
+ }
+
+ const_iterator
+ begin () const
+ {
+ return seq_.rbegin ();
+ }
+
+ const_iterator
+ end () const
+ {
+ return seq_.rend ();
+ }
+
+ private:
+ stack (const stack&);
+ stack& operator= (const stack&);
+ /// The wrapped container.
+ S seq_;
+ };
+
+ /// Present a slice of the top of a stack.
+ template <typename T, typename S = stack<T> >
+ class slice
+ {
+ public:
+ slice (const S& stack, int range)
+ : stack_ (stack)
+ , range_ (range)
+ {}
+
+ const T&
+ operator[] (int i) const
+ {
+ return stack_[range_ - i];
+ }
+
+ private:
+ const S& stack_;
+ int range_;
+ };
/// Empty construction.
variant ()
- : yytypeid_ (YY_NULLPTR)
+ : yybuffer_ ()
+ , yytypeid_ (YY_NULLPTR)
{}
/// Construct and fill.
template <typename T>
- variant (const T& t)
+ variant (YY_RVREF (T) t)
: yytypeid_ (&typeid (T))
{
YYASSERT (sizeof (T) <= S);
- new (yyas_<T> ()) T (t);
+ new (yyas_<T> ()) T (YY_MOVE (t));
}
/// Destruction, allowed only if empty.
/// Instantiate an empty \a T in here.
template <typename T>
T&
- build ()
+ emplace ()
{
YYASSERT (!yytypeid_);
YYASSERT (sizeof (T) <= S);
yytypeid_ = & typeid (T);
- return *new (yyas_<T> ()) T;
+ return *new (yyas_<T> ()) T ();
}
+# if defined __cplusplus && 201103L <= __cplusplus
+ /// Instantiate a \a T in here from \a t.
+ template <typename T, typename U>
+ T&
+ emplace (U&& u)
+ {
+ YYASSERT (!yytypeid_);
+ YYASSERT (sizeof (T) <= S);
+ yytypeid_ = & typeid (T);
+ return *new (yyas_<T> ()) T (std::forward <U>(u));
+ }
+# else
/// Instantiate a \a T in here from \a t.
template <typename T>
T&
- build (const T& t)
+ emplace (const T& t)
{
YYASSERT (!yytypeid_);
YYASSERT (sizeof (T) <= S);
yytypeid_ = & typeid (T);
return *new (yyas_<T> ()) T (t);
}
+# endif
+
+ /// Instantiate an empty \a T in here.
+ /// Obsolete, use emplace.
+ template <typename T>
+ T&
+ build ()
+ {
+ return emplace<T> ();
+ }
+
+ /// Instantiate a \a T in here from \a t.
+ /// Obsolete, use emplace.
+ template <typename T>
+ T&
+ build (const T& t)
+ {
+ return emplace<T> (t);
+ }
/// Accessor to a built \a T.
template <typename T>
T&
as ()
{
+ YYASSERT (yytypeid_);
YYASSERT (*yytypeid_ == typeid (T));
YYASSERT (sizeof (T) <= S);
return *yyas_<T> ();
const T&
as () const
{
+ YYASSERT (yytypeid_);
YYASSERT (*yytypeid_ == typeid (T));
YYASSERT (sizeof (T) <= S);
return *yyas_<T> ();
/// Both variants must be built beforehand, because swapping the actual
/// data requires reading it (with as()), and this is not possible on
/// unconstructed variants: it would require some dynamic testing, which
- /// should not be the variant's responsability.
+ /// should not be the variant's responsibility.
/// Swapping between built and (possibly) non-built is done with
/// variant::move ().
template <typename T>
void
move (self_type& other)
{
- build<T> ();
+# if defined __cplusplus && 201103L <= __cplusplus
+ emplace<T> (std::move (other.as<T> ()));
+# else
+ emplace<T> ();
swap<T> (other);
+# endif
+ other.destroy<T> ();
+ }
+
+# if defined __cplusplus && 201103L <= __cplusplus
+ /// Move the content of \a other to this.
+ template <typename T>
+ void
+ move (self_type&& other)
+ {
+ emplace<T> (std::move (other.as<T> ()));
other.destroy<T> ();
}
+#endif
/// Copy the content of \a other to this.
template <typename T>
void
copy (const self_type& other)
{
- build<T> (other.as<T> ());
+ emplace<T> (other.as<T> ());
}
/// Destroy the stored \a T.
private:
/// Prohibit blind copies.
- self_type& operator=(const self_type&);
+ self_type& operator= (const self_type&);
variant (const self_type&);
/// Accessor to raw memory as \a T.
union union_type
{
// option_repr_type
- char dummy1[sizeof(TokenOption::RepresentationType)];
+ char dummy1[sizeof (TokenOption::RepresentationType)];
// pkt4_field
- char dummy2[sizeof(TokenPkt4::FieldType)];
+ char dummy2[sizeof (TokenPkt4::FieldType)];
// pkt6_field
- char dummy3[sizeof(TokenPkt6::FieldType)];
+ char dummy3[sizeof (TokenPkt6::FieldType)];
// pkt_metadata
- char dummy4[sizeof(TokenPkt::MetadataType)];
+ char dummy4[sizeof (TokenPkt::MetadataType)];
// relay6_field
- char dummy5[sizeof(TokenRelay6Field::FieldType)];
+ char dummy5[sizeof (TokenRelay6Field::FieldType)];
// nest_level
- char dummy6[sizeof(int8_t)];
+ char dummy6[sizeof (int8_t)];
// "constant string"
// "integer"
// "constant hexstring"
// "option name"
// "ip address"
- char dummy7[sizeof(std::string)];
+ char dummy7[sizeof (std::string)];
// option_code
- char dummy8[sizeof(uint16_t)];
+ char dummy8[sizeof (uint16_t)];
// integer_expr
// enterprise_id
- char dummy9[sizeof(uint32_t)];
+ char dummy9[sizeof (uint32_t)];
};
/// Symbol semantic values.
- typedef variant<sizeof(union_type)> semantic_type;
+ typedef variant<sizeof (union_type)> semantic_type;
#else
typedef EVALSTYPE semantic_type;
#endif
/// A complete symbol.
///
/// Expects its Base type to provide access to the symbol type
- /// via type_get().
+ /// via type_get ().
///
/// Provide access to semantic value and location.
template <typename Base>
/// Default constructor.
basic_symbol ();
- /// Copy constructor.
- basic_symbol (const basic_symbol& other);
-
- /// Constructor for valueless symbols, and symbols from each type.
-
- basic_symbol (typename Base::kind_type t, const location_type& l);
-
- basic_symbol (typename Base::kind_type t, const TokenOption::RepresentationType v, const location_type& l);
-
- basic_symbol (typename Base::kind_type t, const TokenPkt4::FieldType v, const location_type& l);
-
- basic_symbol (typename Base::kind_type t, const TokenPkt6::FieldType v, const location_type& l);
-
- basic_symbol (typename Base::kind_type t, const TokenPkt::MetadataType v, const location_type& l);
-
- basic_symbol (typename Base::kind_type t, const TokenRelay6Field::FieldType v, const location_type& l);
-
- basic_symbol (typename Base::kind_type t, const int8_t v, const location_type& l);
+ /// Move or copy constructor.
+ basic_symbol (YY_RVREF (basic_symbol) other);
- basic_symbol (typename Base::kind_type t, const std::string v, const location_type& l);
-
- basic_symbol (typename Base::kind_type t, const uint16_t v, const location_type& l);
-
- basic_symbol (typename Base::kind_type t, const uint32_t v, const location_type& l);
+ /// Constructor for valueless symbols, and symbols from each type.
+ basic_symbol (typename Base::kind_type t, YY_RVREF (location_type) l);
+ basic_symbol (typename Base::kind_type t, YY_RVREF (TokenOption::RepresentationType) v, YY_RVREF (location_type) l);
+ basic_symbol (typename Base::kind_type t, YY_RVREF (TokenPkt4::FieldType) v, YY_RVREF (location_type) l);
+ basic_symbol (typename Base::kind_type t, YY_RVREF (TokenPkt6::FieldType) v, YY_RVREF (location_type) l);
+ basic_symbol (typename Base::kind_type t, YY_RVREF (TokenPkt::MetadataType) v, YY_RVREF (location_type) l);
+ basic_symbol (typename Base::kind_type t, YY_RVREF (TokenRelay6Field::FieldType) v, YY_RVREF (location_type) l);
+ basic_symbol (typename Base::kind_type t, YY_RVREF (int8_t) v, YY_RVREF (location_type) l);
+ basic_symbol (typename Base::kind_type t, YY_RVREF (std::string) v, YY_RVREF (location_type) l);
+ basic_symbol (typename Base::kind_type t, YY_RVREF (uint16_t) v, YY_RVREF (location_type) l);
+ basic_symbol (typename Base::kind_type t, YY_RVREF (uint32_t) v, YY_RVREF (location_type) l);
- /// Constructor for symbols with semantic value.
- basic_symbol (typename Base::kind_type t,
- const semantic_type& v,
- const location_type& l);
/// Destroy the symbol.
~basic_symbol ();
location_type location;
private:
+#if !defined __cplusplus || __cplusplus < 201103L
/// Assignment operator.
basic_symbol& operator= (const basic_symbol& other);
+#endif
};
/// Type access provider for token (enum) based symbols.
/// "External" symbols: returned by the scanner.
typedef basic_symbol<by_type> symbol_type;
+ /// Build a parser object.
+ EvalParser (EvalContext& ctx_yyarg);
+ virtual ~EvalParser ();
+
+ /// Parse. An alias for parse ().
+ /// \returns 0 iff parsing succeeded.
+ int operator() ();
+
+ /// Parse.
+ /// \returns 0 iff parsing succeeded.
+ virtual int parse ();
+
+#if EVALDEBUG
+ /// The current debugging stream.
+ std::ostream& debug_stream () const YY_ATTRIBUTE_PURE;
+ /// Set the current debugging stream.
+ void set_debug_stream (std::ostream &);
+
+ /// Type for debugging levels.
+ typedef int debug_level_type;
+ /// The current debugging level.
+ debug_level_type debug_level () const YY_ATTRIBUTE_PURE;
+ /// Set the current debugging level.
+ void set_debug_level (debug_level_type l);
+#endif
+
+ /// Report a syntax error.
+ /// \param loc where the syntax error is found.
+ /// \param msg a description of the syntax error.
+ virtual void error (const location_type& loc, const std::string& msg);
+
+ /// Report a syntax error.
+ void error (const syntax_error& err);
+
// Symbol constructors declarations.
- static inline
+ static
symbol_type
- make_END (const location_type& l);
+ make_END (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_LPAREN (const location_type& l);
+ make_LPAREN (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_RPAREN (const location_type& l);
+ make_RPAREN (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_NOT (const location_type& l);
+ make_NOT (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_AND (const location_type& l);
+ make_AND (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_OR (const location_type& l);
+ make_OR (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_EQUAL (const location_type& l);
+ make_EQUAL (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_OPTION (const location_type& l);
+ make_OPTION (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_RELAY4 (const location_type& l);
+ make_RELAY4 (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_RELAY6 (const location_type& l);
+ make_RELAY6 (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_MEMBER (const location_type& l);
+ make_MEMBER (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_PEERADDR (const location_type& l);
+ make_PEERADDR (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_LINKADDR (const location_type& l);
+ make_LINKADDR (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_LBRACKET (const location_type& l);
+ make_LBRACKET (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_RBRACKET (const location_type& l);
+ make_RBRACKET (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_DOT (const location_type& l);
+ make_DOT (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_TEXT (const location_type& l);
+ make_TEXT (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_HEX (const location_type& l);
+ make_HEX (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_EXISTS (const location_type& l);
+ make_EXISTS (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_PKT (const location_type& l);
+ make_PKT (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_IFACE (const location_type& l);
+ make_IFACE (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_SRC (const location_type& l);
+ make_SRC (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_DST (const location_type& l);
+ make_DST (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_LEN (const location_type& l);
+ make_LEN (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_PKT4 (const location_type& l);
+ make_PKT4 (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_CHADDR (const location_type& l);
+ make_CHADDR (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_HLEN (const location_type& l);
+ make_HLEN (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_HTYPE (const location_type& l);
+ make_HTYPE (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_CIADDR (const location_type& l);
+ make_CIADDR (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_GIADDR (const location_type& l);
+ make_GIADDR (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_YIADDR (const location_type& l);
+ make_YIADDR (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_SIADDR (const location_type& l);
+ make_SIADDR (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_SUBSTRING (const location_type& l);
+ make_SUBSTRING (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_ALL (const location_type& l);
+ make_ALL (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_COMA (const location_type& l);
+ make_COMA (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_CONCAT (const location_type& l);
+ make_CONCAT (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_IFELSE (const location_type& l);
+ make_IFELSE (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_TOHEXSTRING (const location_type& l);
+ make_TOHEXSTRING (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_PKT6 (const location_type& l);
+ make_PKT6 (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_MSGTYPE (const location_type& l);
+ make_MSGTYPE (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_TRANSID (const location_type& l);
+ make_TRANSID (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_VENDOR_CLASS (const location_type& l);
+ make_VENDOR_CLASS (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_VENDOR (const location_type& l);
+ make_VENDOR (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_ANY (const location_type& l);
+ make_ANY (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_DATA (const location_type& l);
+ make_DATA (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_ENTERPRISE (const location_type& l);
+ make_ENTERPRISE (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_TOPLEVEL_BOOL (const location_type& l);
+ make_TOPLEVEL_BOOL (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_TOPLEVEL_STRING (const location_type& l);
+ make_TOPLEVEL_STRING (YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_STRING (const std::string& v, const location_type& l);
+ make_STRING (YY_COPY (std::string) v, YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_INTEGER (const std::string& v, const location_type& l);
+ make_INTEGER (YY_COPY (std::string) v, YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_HEXSTRING (const std::string& v, const location_type& l);
+ make_HEXSTRING (YY_COPY (std::string) v, YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_OPTION_NAME (const std::string& v, const location_type& l);
+ make_OPTION_NAME (YY_COPY (std::string) v, YY_COPY (location_type) l);
- static inline
+ static
symbol_type
- make_IP_ADDRESS (const std::string& v, const location_type& l);
-
-
- /// Build a parser object.
- EvalParser (EvalContext& ctx_yyarg);
- virtual ~EvalParser ();
-
- /// Parse.
- /// \returns 0 iff parsing succeeded.
- virtual int parse ();
-
-#if EVALDEBUG
- /// The current debugging stream.
- std::ostream& debug_stream () const YY_ATTRIBUTE_PURE;
- /// Set the current debugging stream.
- void set_debug_stream (std::ostream &);
-
- /// Type for debugging levels.
- typedef int debug_level_type;
- /// The current debugging level.
- debug_level_type debug_level () const YY_ATTRIBUTE_PURE;
- /// Set the current debugging level.
- void set_debug_level (debug_level_type l);
-#endif
+ make_IP_ADDRESS (YY_COPY (std::string) v, YY_COPY (location_type) l);
- /// Report a syntax error.
- /// \param loc where the syntax error is found.
- /// \param msg a description of the syntax error.
- virtual void error (const location_type& loc, const std::string& msg);
- /// Report a syntax error.
- void error (const syntax_error& err);
private:
/// This class is not copyable.
// Tables.
// YYPACT[STATE-NUM] -- Index in YYTABLE of the portion describing
// STATE-NUM.
- static const short int yypact_[];
+ static const short yypact_[];
// YYDEFACT[STATE-NUM] -- Default reduction number in state STATE-NUM.
// Performed when YYTABLE does not specify something else to do. Zero
static const unsigned char yydefact_[];
// YYPGOTO[NTERM-NUM].
- static const short int yypgoto_[];
+ static const short yypgoto_[];
// YYDEFGOTO[NTERM-NUM].
- static const short int yydefgoto_[];
+ static const short yydefgoto_[];
// YYTABLE[YYPACT[STATE-NUM]] -- What to do in state STATE-NUM. If
// positive, shift that token. If negative, reduce the rule whose
static const char* const yytname_[];
#if EVALDEBUG
// YYRLINE[YYN] -- Source line where rule number YYN was defined.
- static const unsigned short int yyrline_[];
+ static const unsigned short yyrline_[];
/// Report on the debug stream that the rule \a r is going to be reduced.
virtual void yy_reduce_print_ (int r);
/// Print the state stack on the debug stream.
virtual void yystack_print_ ();
- // Debugging.
+ /// Debugging level.
int yydebug_;
+ /// Debug stream.
std::ostream* yycdebug_;
/// \brief Display a symbol type, value and location.
typedef basic_symbol<by_state> super_type;
/// Construct an empty symbol.
stack_symbol_type ();
- /// Copy construct.
- stack_symbol_type (const stack_symbol_type& that);
+ /// Move or copy construction.
+ stack_symbol_type (YY_RVREF (stack_symbol_type) that);
/// Steal the contents from \a sym to build this.
- stack_symbol_type (state_type s, symbol_type& sym);
- /// Assignment, needed by push_back.
- stack_symbol_type& operator= (const stack_symbol_type& that);
+ stack_symbol_type (state_type s, YY_MOVE_REF (symbol_type) sym);
+#if !defined __cplusplus || __cplusplus < 201103L
+ /// Assignment, needed by push_back by some old implementations.
+ /// Moves the contents of that.
+ stack_symbol_type& operator= (stack_symbol_type& that);
+#endif
};
/// Stack type.
/// Push a new state on the stack.
/// \param m a debug message to display
/// if null, no trace is output.
- /// \param s the symbol
+ /// \param sym the symbol
/// \warning the contents of \a s.value is stolen.
- void yypush_ (const char* m, stack_symbol_type& s);
+ void yypush_ (const char* m, YY_MOVE_REF (stack_symbol_type) sym);
/// Push a new look ahead token on the state on the stack.
/// \param m a debug message to display
/// if null, no trace is output.
/// \param s the state
/// \param sym the symbol (for its value and location).
- /// \warning the contents of \a s.value is stolen.
- void yypush_ (const char* m, state_type s, symbol_type& sym);
+ /// \warning the contents of \a sym.value is stolen.
+ void yypush_ (const char* m, state_type s, YY_MOVE_REF (symbol_type) sym);
- /// Pop \a n symbols the three stacks.
- void yypop_ (unsigned n = 1);
+ /// Pop \a n symbols from the stack.
+ void yypop_ (int n = 1);
/// Constants.
enum
template <typename Base>
EvalParser::basic_symbol<Base>::basic_symbol ()
: value ()
+ , location ()
{}
template <typename Base>
- EvalParser::basic_symbol<Base>::basic_symbol (const basic_symbol& other)
- : Base (other)
+ EvalParser::basic_symbol<Base>::basic_symbol (YY_RVREF (basic_symbol) other)
+ : Base (YY_MOVE (other))
, value ()
- , location (other.location)
+ , location (YY_MOVE (other.location))
{
switch (other.type_get ())
{
case 62: // option_repr_type
- value.copy< TokenOption::RepresentationType > (other.value);
+ value.YY_MOVE_OR_COPY< TokenOption::RepresentationType > (YY_MOVE (other.value));
break;
case 66: // pkt4_field
- value.copy< TokenPkt4::FieldType > (other.value);
+ value.YY_MOVE_OR_COPY< TokenPkt4::FieldType > (YY_MOVE (other.value));
break;
case 67: // pkt6_field
- value.copy< TokenPkt6::FieldType > (other.value);
+ value.YY_MOVE_OR_COPY< TokenPkt6::FieldType > (YY_MOVE (other.value));
break;
case 64: // pkt_metadata
- value.copy< TokenPkt::MetadataType > (other.value);
+ value.YY_MOVE_OR_COPY< TokenPkt::MetadataType > (YY_MOVE (other.value));
break;
case 68: // relay6_field
- value.copy< TokenRelay6Field::FieldType > (other.value);
+ value.YY_MOVE_OR_COPY< TokenRelay6Field::FieldType > (YY_MOVE (other.value));
break;
case 63: // nest_level
- value.copy< int8_t > (other.value);
+ value.YY_MOVE_OR_COPY< int8_t > (YY_MOVE (other.value));
break;
case 50: // "constant string"
case 52: // "constant hexstring"
case 53: // "option name"
case 54: // "ip address"
- value.copy< std::string > (other.value);
+ value.YY_MOVE_OR_COPY< std::string > (YY_MOVE (other.value));
break;
case 61: // option_code
- value.copy< uint16_t > (other.value);
+ value.YY_MOVE_OR_COPY< uint16_t > (YY_MOVE (other.value));
break;
case 60: // integer_expr
case 65: // enterprise_id
- value.copy< uint32_t > (other.value);
+ value.YY_MOVE_OR_COPY< uint32_t > (YY_MOVE (other.value));
break;
default:
}
- template <typename Base>
- EvalParser::basic_symbol<Base>::basic_symbol (typename Base::kind_type t, const semantic_type& v, const location_type& l)
- : Base (t)
- , value ()
- , location (l)
- {
- (void) v;
- switch (this->type_get ())
- {
- case 62: // option_repr_type
- value.copy< TokenOption::RepresentationType > (v);
- break;
-
- case 66: // pkt4_field
- value.copy< TokenPkt4::FieldType > (v);
- break;
-
- case 67: // pkt6_field
- value.copy< TokenPkt6::FieldType > (v);
- break;
-
- case 64: // pkt_metadata
- value.copy< TokenPkt::MetadataType > (v);
- break;
-
- case 68: // relay6_field
- value.copy< TokenRelay6Field::FieldType > (v);
- break;
-
- case 63: // nest_level
- value.copy< int8_t > (v);
- break;
-
- case 50: // "constant string"
- case 51: // "integer"
- case 52: // "constant hexstring"
- case 53: // "option name"
- case 54: // "ip address"
- value.copy< std::string > (v);
- break;
-
- case 61: // option_code
- value.copy< uint16_t > (v);
- break;
-
- case 60: // integer_expr
- case 65: // enterprise_id
- value.copy< uint32_t > (v);
- break;
-
- default:
- break;
- }
-}
-
// Implementation of basic_symbol constructor for each type.
-
template <typename Base>
- EvalParser::basic_symbol<Base>::basic_symbol (typename Base::kind_type t, const location_type& l)
+ EvalParser::basic_symbol<Base>::basic_symbol (typename Base::kind_type t, YY_RVREF (location_type) l)
: Base (t)
- , value ()
- , location (l)
+ , location (YY_MOVE (l))
{}
template <typename Base>
- EvalParser::basic_symbol<Base>::basic_symbol (typename Base::kind_type t, const TokenOption::RepresentationType v, const location_type& l)
+ EvalParser::basic_symbol<Base>::basic_symbol (typename Base::kind_type t, YY_RVREF (TokenOption::RepresentationType) v, YY_RVREF (location_type) l)
: Base (t)
- , value (v)
- , location (l)
+ , value (YY_MOVE (v))
+ , location (YY_MOVE (l))
{}
template <typename Base>
- EvalParser::basic_symbol<Base>::basic_symbol (typename Base::kind_type t, const TokenPkt4::FieldType v, const location_type& l)
+ EvalParser::basic_symbol<Base>::basic_symbol (typename Base::kind_type t, YY_RVREF (TokenPkt4::FieldType) v, YY_RVREF (location_type) l)
: Base (t)
- , value (v)
- , location (l)
+ , value (YY_MOVE (v))
+ , location (YY_MOVE (l))
{}
template <typename Base>
- EvalParser::basic_symbol<Base>::basic_symbol (typename Base::kind_type t, const TokenPkt6::FieldType v, const location_type& l)
+ EvalParser::basic_symbol<Base>::basic_symbol (typename Base::kind_type t, YY_RVREF (TokenPkt6::FieldType) v, YY_RVREF (location_type) l)
: Base (t)
- , value (v)
- , location (l)
+ , value (YY_MOVE (v))
+ , location (YY_MOVE (l))
{}
template <typename Base>
- EvalParser::basic_symbol<Base>::basic_symbol (typename Base::kind_type t, const TokenPkt::MetadataType v, const location_type& l)
+ EvalParser::basic_symbol<Base>::basic_symbol (typename Base::kind_type t, YY_RVREF (TokenPkt::MetadataType) v, YY_RVREF (location_type) l)
: Base (t)
- , value (v)
- , location (l)
+ , value (YY_MOVE (v))
+ , location (YY_MOVE (l))
{}
template <typename Base>
- EvalParser::basic_symbol<Base>::basic_symbol (typename Base::kind_type t, const TokenRelay6Field::FieldType v, const location_type& l)
+ EvalParser::basic_symbol<Base>::basic_symbol (typename Base::kind_type t, YY_RVREF (TokenRelay6Field::FieldType) v, YY_RVREF (location_type) l)
: Base (t)
- , value (v)
- , location (l)
+ , value (YY_MOVE (v))
+ , location (YY_MOVE (l))
{}
template <typename Base>
- EvalParser::basic_symbol<Base>::basic_symbol (typename Base::kind_type t, const int8_t v, const location_type& l)
+ EvalParser::basic_symbol<Base>::basic_symbol (typename Base::kind_type t, YY_RVREF (int8_t) v, YY_RVREF (location_type) l)
: Base (t)
- , value (v)
- , location (l)
+ , value (YY_MOVE (v))
+ , location (YY_MOVE (l))
{}
template <typename Base>
- EvalParser::basic_symbol<Base>::basic_symbol (typename Base::kind_type t, const std::string v, const location_type& l)
+ EvalParser::basic_symbol<Base>::basic_symbol (typename Base::kind_type t, YY_RVREF (std::string) v, YY_RVREF (location_type) l)
: Base (t)
- , value (v)
- , location (l)
+ , value (YY_MOVE (v))
+ , location (YY_MOVE (l))
{}
template <typename Base>
- EvalParser::basic_symbol<Base>::basic_symbol (typename Base::kind_type t, const uint16_t v, const location_type& l)
+ EvalParser::basic_symbol<Base>::basic_symbol (typename Base::kind_type t, YY_RVREF (uint16_t) v, YY_RVREF (location_type) l)
: Base (t)
- , value (v)
- , location (l)
+ , value (YY_MOVE (v))
+ , location (YY_MOVE (l))
{}
template <typename Base>
- EvalParser::basic_symbol<Base>::basic_symbol (typename Base::kind_type t, const uint32_t v, const location_type& l)
+ EvalParser::basic_symbol<Base>::basic_symbol (typename Base::kind_type t, YY_RVREF (uint32_t) v, YY_RVREF (location_type) l)
: Base (t)
- , value (v)
- , location (l)
+ , value (YY_MOVE (v))
+ , location (YY_MOVE (l))
{}
+
template <typename Base>
EvalParser::basic_symbol<Base>::~basic_symbol ()
{
switch (this->type_get ())
{
case 62: // option_repr_type
- value.move< TokenOption::RepresentationType > (s.value);
+ value.move< TokenOption::RepresentationType > (YY_MOVE (s.value));
break;
case 66: // pkt4_field
- value.move< TokenPkt4::FieldType > (s.value);
+ value.move< TokenPkt4::FieldType > (YY_MOVE (s.value));
break;
case 67: // pkt6_field
- value.move< TokenPkt6::FieldType > (s.value);
+ value.move< TokenPkt6::FieldType > (YY_MOVE (s.value));
break;
case 64: // pkt_metadata
- value.move< TokenPkt::MetadataType > (s.value);
+ value.move< TokenPkt::MetadataType > (YY_MOVE (s.value));
break;
case 68: // relay6_field
- value.move< TokenRelay6Field::FieldType > (s.value);
+ value.move< TokenRelay6Field::FieldType > (YY_MOVE (s.value));
break;
case 63: // nest_level
- value.move< int8_t > (s.value);
+ value.move< int8_t > (YY_MOVE (s.value));
break;
case 50: // "constant string"
case 52: // "constant hexstring"
case 53: // "option name"
case 54: // "ip address"
- value.move< std::string > (s.value);
+ value.move< std::string > (YY_MOVE (s.value));
break;
case 61: // option_code
- value.move< uint16_t > (s.value);
+ value.move< uint16_t > (YY_MOVE (s.value));
break;
case 60: // integer_expr
case 65: // enterprise_id
- value.move< uint32_t > (s.value);
+ value.move< uint32_t > (YY_MOVE (s.value));
break;
default:
break;
}
- location = s.location;
+ location = YY_MOVE (s.location);
}
// by_type.
// YYTOKNUM[NUM] -- (External) token number corresponding to the
// (internal) symbol number NUM (which must be that of a token). */
static
- const unsigned short int
+ const unsigned short
yytoken_number_[] =
{
0, 256, 257, 258, 259, 260, 261, 262, 263, 264,
};
return static_cast<token_type> (yytoken_number_[type]);
}
+
// Implementation of make_symbol for each symbol type.
+ inline
EvalParser::symbol_type
- EvalParser::make_END (const location_type& l)
+ EvalParser::make_END (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_END, l);
+ return symbol_type (token::TOKEN_END, YY_MOVE (l));
}
+ inline
EvalParser::symbol_type
- EvalParser::make_LPAREN (const location_type& l)
+ EvalParser::make_LPAREN (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_LPAREN, l);
+ return symbol_type (token::TOKEN_LPAREN, YY_MOVE (l));
}
+ inline
EvalParser::symbol_type
- EvalParser::make_RPAREN (const location_type& l)
+ EvalParser::make_RPAREN (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_RPAREN, l);
+ return symbol_type (token::TOKEN_RPAREN, YY_MOVE (l));
}
+ inline
EvalParser::symbol_type
- EvalParser::make_NOT (const location_type& l)
+ EvalParser::make_NOT (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_NOT, l);
+ return symbol_type (token::TOKEN_NOT, YY_MOVE (l));
}
+ inline
EvalParser::symbol_type
- EvalParser::make_AND (const location_type& l)
+ EvalParser::make_AND (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_AND, l);
+ return symbol_type (token::TOKEN_AND, YY_MOVE (l));
}
+ inline
EvalParser::symbol_type
- EvalParser::make_OR (const location_type& l)
+ EvalParser::make_OR (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_OR, l);
+ return symbol_type (token::TOKEN_OR, YY_MOVE (l));
}
+ inline
EvalParser::symbol_type
- EvalParser::make_EQUAL (const location_type& l)
+ EvalParser::make_EQUAL (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_EQUAL, l);
+ return symbol_type (token::TOKEN_EQUAL, YY_MOVE (l));
}
+ inline
EvalParser::symbol_type
- EvalParser::make_OPTION (const location_type& l)
+ EvalParser::make_OPTION (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_OPTION, l);
+ return symbol_type (token::TOKEN_OPTION, YY_MOVE (l));
}
+ inline
EvalParser::symbol_type
- EvalParser::make_RELAY4 (const location_type& l)
+ EvalParser::make_RELAY4 (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_RELAY4, l);
+ return symbol_type (token::TOKEN_RELAY4, YY_MOVE (l));
}
+ inline
EvalParser::symbol_type
- EvalParser::make_RELAY6 (const location_type& l)
+ EvalParser::make_RELAY6 (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_RELAY6, l);
+ return symbol_type (token::TOKEN_RELAY6, YY_MOVE (l));
}
+ inline
EvalParser::symbol_type
- EvalParser::make_MEMBER (const location_type& l)
+ EvalParser::make_MEMBER (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_MEMBER, l);
+ return symbol_type (token::TOKEN_MEMBER, YY_MOVE (l));
}
+ inline
EvalParser::symbol_type
- EvalParser::make_PEERADDR (const location_type& l)
+ EvalParser::make_PEERADDR (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_PEERADDR, l);
+ return symbol_type (token::TOKEN_PEERADDR, YY_MOVE (l));
}
+ inline
EvalParser::symbol_type
- EvalParser::make_LINKADDR (const location_type& l)
+ EvalParser::make_LINKADDR (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_LINKADDR, l);
+ return symbol_type (token::TOKEN_LINKADDR, YY_MOVE (l));
}
+ inline
EvalParser::symbol_type
- EvalParser::make_LBRACKET (const location_type& l)
+ EvalParser::make_LBRACKET (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_LBRACKET, l);
+ return symbol_type (token::TOKEN_LBRACKET, YY_MOVE (l));
}
+ inline
EvalParser::symbol_type
- EvalParser::make_RBRACKET (const location_type& l)
+ EvalParser::make_RBRACKET (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_RBRACKET, l);
+ return symbol_type (token::TOKEN_RBRACKET, YY_MOVE (l));
}
+ inline
EvalParser::symbol_type
- EvalParser::make_DOT (const location_type& l)
+ EvalParser::make_DOT (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_DOT, l);
+ return symbol_type (token::TOKEN_DOT, YY_MOVE (l));
}
+ inline
EvalParser::symbol_type
- EvalParser::make_TEXT (const location_type& l)
+ EvalParser::make_TEXT (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_TEXT, l);
+ return symbol_type (token::TOKEN_TEXT, YY_MOVE (l));
}
+ inline
EvalParser::symbol_type
- EvalParser::make_HEX (const location_type& l)
+ EvalParser::make_HEX (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_HEX, l);
+ return symbol_type (token::TOKEN_HEX, YY_MOVE (l));
}
+ inline
EvalParser::symbol_type
- EvalParser::make_EXISTS (const location_type& l)
+ EvalParser::make_EXISTS (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_EXISTS, l);
+ return symbol_type (token::TOKEN_EXISTS, YY_MOVE (l));
}
+ inline
EvalParser::symbol_type
- EvalParser::make_PKT (const location_type& l)
+ EvalParser::make_PKT (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_PKT, l);
+ return symbol_type (token::TOKEN_PKT, YY_MOVE (l));
}
+ inline
EvalParser::symbol_type
- EvalParser::make_IFACE (const location_type& l)
+ EvalParser::make_IFACE (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_IFACE, l);
+ return symbol_type (token::TOKEN_IFACE, YY_MOVE (l));
}
+ inline
EvalParser::symbol_type
- EvalParser::make_SRC (const location_type& l)
+ EvalParser::make_SRC (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_SRC, l);
+ return symbol_type (token::TOKEN_SRC, YY_MOVE (l));
}
+ inline
EvalParser::symbol_type
- EvalParser::make_DST (const location_type& l)
+ EvalParser::make_DST (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_DST, l);
+ return symbol_type (token::TOKEN_DST, YY_MOVE (l));
}
+ inline
EvalParser::symbol_type
- EvalParser::make_LEN (const location_type& l)
+ EvalParser::make_LEN (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_LEN, l);
+ return symbol_type (token::TOKEN_LEN, YY_MOVE (l));
}
+ inline
EvalParser::symbol_type
- EvalParser::make_PKT4 (const location_type& l)
+ EvalParser::make_PKT4 (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_PKT4, l);
+ return symbol_type (token::TOKEN_PKT4, YY_MOVE (l));
}
+ inline
EvalParser::symbol_type
- EvalParser::make_CHADDR (const location_type& l)
+ EvalParser::make_CHADDR (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_CHADDR, l);
+ return symbol_type (token::TOKEN_CHADDR, YY_MOVE (l));
}
+ inline
EvalParser::symbol_type
- EvalParser::make_HLEN (const location_type& l)
+ EvalParser::make_HLEN (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_HLEN, l);
+ return symbol_type (token::TOKEN_HLEN, YY_MOVE (l));
}
+ inline
EvalParser::symbol_type
- EvalParser::make_HTYPE (const location_type& l)
+ EvalParser::make_HTYPE (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_HTYPE, l);
+ return symbol_type (token::TOKEN_HTYPE, YY_MOVE (l));
}
+ inline
EvalParser::symbol_type
- EvalParser::make_CIADDR (const location_type& l)
+ EvalParser::make_CIADDR (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_CIADDR, l);
+ return symbol_type (token::TOKEN_CIADDR, YY_MOVE (l));
}
+ inline
EvalParser::symbol_type
- EvalParser::make_GIADDR (const location_type& l)
+ EvalParser::make_GIADDR (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_GIADDR, l);
+ return symbol_type (token::TOKEN_GIADDR, YY_MOVE (l));
}
+ inline
EvalParser::symbol_type
- EvalParser::make_YIADDR (const location_type& l)
+ EvalParser::make_YIADDR (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_YIADDR, l);
+ return symbol_type (token::TOKEN_YIADDR, YY_MOVE (l));
}
+ inline
EvalParser::symbol_type
- EvalParser::make_SIADDR (const location_type& l)
+ EvalParser::make_SIADDR (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_SIADDR, l);
+ return symbol_type (token::TOKEN_SIADDR, YY_MOVE (l));
}
+ inline
EvalParser::symbol_type
- EvalParser::make_SUBSTRING (const location_type& l)
+ EvalParser::make_SUBSTRING (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_SUBSTRING, l);
+ return symbol_type (token::TOKEN_SUBSTRING, YY_MOVE (l));
}
+ inline
EvalParser::symbol_type
- EvalParser::make_ALL (const location_type& l)
+ EvalParser::make_ALL (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_ALL, l);
+ return symbol_type (token::TOKEN_ALL, YY_MOVE (l));
}
+ inline
EvalParser::symbol_type
- EvalParser::make_COMA (const location_type& l)
+ EvalParser::make_COMA (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_COMA, l);
+ return symbol_type (token::TOKEN_COMA, YY_MOVE (l));
}
+ inline
EvalParser::symbol_type
- EvalParser::make_CONCAT (const location_type& l)
+ EvalParser::make_CONCAT (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_CONCAT, l);
+ return symbol_type (token::TOKEN_CONCAT, YY_MOVE (l));
}
+ inline
EvalParser::symbol_type
- EvalParser::make_IFELSE (const location_type& l)
+ EvalParser::make_IFELSE (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_IFELSE, l);
+ return symbol_type (token::TOKEN_IFELSE, YY_MOVE (l));
}
+ inline
EvalParser::symbol_type
- EvalParser::make_TOHEXSTRING (const location_type& l)
+ EvalParser::make_TOHEXSTRING (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_TOHEXSTRING, l);
+ return symbol_type (token::TOKEN_TOHEXSTRING, YY_MOVE (l));
}
+ inline
EvalParser::symbol_type
- EvalParser::make_PKT6 (const location_type& l)
+ EvalParser::make_PKT6 (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_PKT6, l);
+ return symbol_type (token::TOKEN_PKT6, YY_MOVE (l));
}
+ inline
EvalParser::symbol_type
- EvalParser::make_MSGTYPE (const location_type& l)
+ EvalParser::make_MSGTYPE (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_MSGTYPE, l);
+ return symbol_type (token::TOKEN_MSGTYPE, YY_MOVE (l));
}
+ inline
EvalParser::symbol_type
- EvalParser::make_TRANSID (const location_type& l)
+ EvalParser::make_TRANSID (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_TRANSID, l);
+ return symbol_type (token::TOKEN_TRANSID, YY_MOVE (l));
}
+ inline
EvalParser::symbol_type
- EvalParser::make_VENDOR_CLASS (const location_type& l)
+ EvalParser::make_VENDOR_CLASS (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_VENDOR_CLASS, l);
+ return symbol_type (token::TOKEN_VENDOR_CLASS, YY_MOVE (l));
}
+ inline
EvalParser::symbol_type
- EvalParser::make_VENDOR (const location_type& l)
+ EvalParser::make_VENDOR (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_VENDOR, l);
+ return symbol_type (token::TOKEN_VENDOR, YY_MOVE (l));
}
+ inline
EvalParser::symbol_type
- EvalParser::make_ANY (const location_type& l)
+ EvalParser::make_ANY (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_ANY, l);
+ return symbol_type (token::TOKEN_ANY, YY_MOVE (l));
}
+ inline
EvalParser::symbol_type
- EvalParser::make_DATA (const location_type& l)
+ EvalParser::make_DATA (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_DATA, l);
+ return symbol_type (token::TOKEN_DATA, YY_MOVE (l));
}
+ inline
EvalParser::symbol_type
- EvalParser::make_ENTERPRISE (const location_type& l)
+ EvalParser::make_ENTERPRISE (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_ENTERPRISE, l);
+ return symbol_type (token::TOKEN_ENTERPRISE, YY_MOVE (l));
}
+ inline
EvalParser::symbol_type
- EvalParser::make_TOPLEVEL_BOOL (const location_type& l)
+ EvalParser::make_TOPLEVEL_BOOL (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_TOPLEVEL_BOOL, l);
+ return symbol_type (token::TOKEN_TOPLEVEL_BOOL, YY_MOVE (l));
}
+ inline
EvalParser::symbol_type
- EvalParser::make_TOPLEVEL_STRING (const location_type& l)
+ EvalParser::make_TOPLEVEL_STRING (YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_TOPLEVEL_STRING, l);
+ return symbol_type (token::TOKEN_TOPLEVEL_STRING, YY_MOVE (l));
}
+ inline
EvalParser::symbol_type
- EvalParser::make_STRING (const std::string& v, const location_type& l)
+ EvalParser::make_STRING (YY_COPY (std::string) v, YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_STRING, v, l);
+ return symbol_type (token::TOKEN_STRING, YY_MOVE (v), YY_MOVE (l));
}
+ inline
EvalParser::symbol_type
- EvalParser::make_INTEGER (const std::string& v, const location_type& l)
+ EvalParser::make_INTEGER (YY_COPY (std::string) v, YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_INTEGER, v, l);
+ return symbol_type (token::TOKEN_INTEGER, YY_MOVE (v), YY_MOVE (l));
}
+ inline
EvalParser::symbol_type
- EvalParser::make_HEXSTRING (const std::string& v, const location_type& l)
+ EvalParser::make_HEXSTRING (YY_COPY (std::string) v, YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_HEXSTRING, v, l);
+ return symbol_type (token::TOKEN_HEXSTRING, YY_MOVE (v), YY_MOVE (l));
}
+ inline
EvalParser::symbol_type
- EvalParser::make_OPTION_NAME (const std::string& v, const location_type& l)
+ EvalParser::make_OPTION_NAME (YY_COPY (std::string) v, YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_OPTION_NAME, v, l);
+ return symbol_type (token::TOKEN_OPTION_NAME, YY_MOVE (v), YY_MOVE (l));
}
+ inline
EvalParser::symbol_type
- EvalParser::make_IP_ADDRESS (const std::string& v, const location_type& l)
+ EvalParser::make_IP_ADDRESS (YY_COPY (std::string) v, YY_COPY (location_type) l)
{
- return symbol_type (token::TOKEN_IP_ADDRESS, v, l);
+ return symbol_type (token::TOKEN_IP_ADDRESS, YY_MOVE (v), YY_MOVE (l));
}
-#line 14 "parser.yy" // lalr1.cc:379
+#line 14 "parser.yy" // lalr1.cc:404
} } // isc::eval
-#line 1727 "parser.h" // lalr1.cc:379
+#line 1912 "parser.h" // lalr1.cc:404
-// Generated 201811151407
-// A Bison parser, made by GNU Bison 3.0.5.
-
-// Positions for Bison parsers in C++
-
-// Copyright (C) 2002-2015, 2018 Free Software Foundation, Inc.
-
-// This program is free software: you can redistribute it and/or modify
-// it under the terms of the GNU General Public License as published by
-// the Free Software Foundation, either version 3 of the License, or
-// (at your option) any later version.
-
-// This program is distributed in the hope that it will be useful,
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-// GNU General Public License for more details.
-
-// You should have received a copy of the GNU General Public License
-// along with this program. If not, see <http://www.gnu.org/licenses/>.
-
-// As a special exception, you may create a larger work that contains
-// part or all of the Bison parser skeleton and distribute that work
-// under terms of your choice, so long as that work isn't itself a
-// parser generator using the skeleton or a modified version thereof
-// as a parser skeleton. Alternatively, if you modify or redistribute
-// the parser skeleton itself, you may (at your option) remove this
-// special exception, which will cause the skeleton and the resulting
-// Bison output files to be licensed under the GNU General Public
-// License without this special exception.
-
-// This special exception was added by the Free Software Foundation in
-// version 2.2 of Bison.
-
-/**
- ** \file position.hh
- ** Define the isc::eval::position class.
- */
-
-#ifndef YY_EVAL_POSITION_HH_INCLUDED
-# define YY_EVAL_POSITION_HH_INCLUDED
-
-# include <algorithm> // std::max
-# include <iostream>
-# include <string>
-
-# ifndef YY_NULLPTR
-# if defined __cplusplus && 201103L <= __cplusplus
-# define YY_NULLPTR nullptr
-# else
-# define YY_NULLPTR 0
-# endif
-# endif
-
-#line 14 "parser.yy" // location.cc:292
-namespace isc { namespace eval {
-#line 56 "position.hh" // location.cc:292
- /// Abstract a position.
- class position
- {
- public:
- /// Construct a position.
- explicit position (std::string* f = YY_NULLPTR,
- unsigned l = 1u,
- unsigned c = 1u)
- : filename (f)
- , line (l)
- , column (c)
- {}
-
-
- /// Initialization.
- void initialize (std::string* fn = YY_NULLPTR,
- unsigned l = 1u,
- unsigned c = 1u)
- {
- filename = fn;
- line = l;
- column = c;
- }
-
- /** \name Line and Column related manipulators
- ** \{ */
- /// (line related) Advance to the COUNT next lines.
- void lines (int count = 1)
- {
- if (count)
- {
- column = 1u;
- line = add_ (line, count, 1);
- }
- }
-
- /// (column related) Advance to the COUNT next columns.
- void columns (int count = 1)
- {
- column = add_ (column, count, 1);
- }
- /** \} */
-
- /// File name to which this position refers.
- std::string* filename;
- /// Current line number.
- unsigned line;
- /// Current column number.
- unsigned column;
-
- private:
- /// Compute max(min, lhs+rhs) (provided min <= lhs).
- static unsigned add_ (unsigned lhs, int rhs, unsigned min)
- {
- return (0 < rhs || -static_cast<unsigned>(rhs) < lhs
- ? rhs + lhs
- : min);
- }
- };
-
- /// Add \a width columns, in place.
- inline position&
- operator+= (position& res, int width)
- {
- res.columns (width);
- return res;
- }
-
- /// Add \a width columns.
- inline position
- operator+ (position res, int width)
- {
- return res += width;
- }
-
- /// Subtract \a width columns, in place.
- inline position&
- operator-= (position& res, int width)
- {
- return res += -width;
- }
-
- /// Subtract \a width columns.
- inline position
- operator- (position res, int width)
- {
- return res -= width;
- }
-
- /// Compare two position objects.
- inline bool
- operator== (const position& pos1, const position& pos2)
- {
- return (pos1.line == pos2.line
- && pos1.column == pos2.column
- && (pos1.filename == pos2.filename
- || (pos1.filename && pos2.filename
- && *pos1.filename == *pos2.filename)));
- }
-
- /// Compare two position objects.
- inline bool
- operator!= (const position& pos1, const position& pos2)
- {
- return !(pos1 == pos2);
- }
-
- /** \brief Intercept output stream redirection.
- ** \param ostr the destination output stream
- ** \param pos a reference to the position to redirect
- */
- template <typename YYChar>
- inline std::basic_ostream<YYChar>&
- operator<< (std::basic_ostream<YYChar>& ostr, const position& pos)
- {
- if (pos.filename)
- ostr << *pos.filename << ':';
- return ostr << pos.line << '.' << pos.column;
- }
-
-#line 14 "parser.yy" // location.cc:292
-} } // isc::eval
-#line 179 "position.hh" // location.cc:292
-#endif // !YY_EVAL_POSITION_HH_INCLUDED
+// Generated 201811172152
+// A Bison parser, made by GNU Bison 3.2.1.
+
+// Starting with Bison 3.2, this file is useless: the structure it
+// used to define is now defined in "location.hh".
+//
+// To get rid of this file:
+// 1. add 'require "3.2"' (or newer) to your grammar file
+// 2. remove references to this file from your build system
+// 3. if you used to include it, include "location.hh" instead.
+
+#include "location.hh"
-// Generated 201811151407
-// A Bison parser, made by GNU Bison 3.0.5.
-
-// Stack handling for Bison parsers in C++
-
-// Copyright (C) 2002-2015, 2018 Free Software Foundation, Inc.
-
-// This program is free software: you can redistribute it and/or modify
-// it under the terms of the GNU General Public License as published by
-// the Free Software Foundation, either version 3 of the License, or
-// (at your option) any later version.
-
-// This program is distributed in the hope that it will be useful,
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-// GNU General Public License for more details.
-
-// You should have received a copy of the GNU General Public License
-// along with this program. If not, see <http://www.gnu.org/licenses/>.
-
-// As a special exception, you may create a larger work that contains
-// part or all of the Bison parser skeleton and distribute that work
-// under terms of your choice, so long as that work isn't itself a
-// parser generator using the skeleton or a modified version thereof
-// as a parser skeleton. Alternatively, if you modify or redistribute
-// the parser skeleton itself, you may (at your option) remove this
-// special exception, which will cause the skeleton and the resulting
-// Bison output files to be licensed under the GNU General Public
-// License without this special exception.
-
-// This special exception was added by the Free Software Foundation in
-// version 2.2 of Bison.
-
-/**
- ** \file stack.hh
- ** Define the isc::eval::stack class.
- */
-
-#ifndef YY_EVAL_STACK_HH_INCLUDED
-# define YY_EVAL_STACK_HH_INCLUDED
-
-# include <vector>
-
-#line 14 "parser.yy" // stack.hh:131
-namespace isc { namespace eval {
-#line 46 "stack.hh" // stack.hh:131
- /// A stack with random access from its top.
- template <class T, class S = std::vector<T> >
- class stack
- {
- public:
- // Hide our reversed order.
- typedef typename S::reverse_iterator iterator;
- typedef typename S::const_reverse_iterator const_iterator;
-
- stack ()
- : seq_ ()
- {
- seq_.reserve (200);
- }
-
- stack (unsigned n)
- : seq_ (n)
- {}
-
- /// Random access.
- ///
- /// Index 0 returns the topmost element.
- T&
- operator[] (unsigned i)
- {
- return seq_[seq_.size () - 1 - i];
- }
-
- /// Random access.
- ///
- /// Index 0 returns the topmost element.
- const T&
- operator[] (unsigned i) const
- {
- return seq_[seq_.size () - 1 - i];
- }
-
- /// Steal the contents of \a t.
- ///
- /// Close to move-semantics.
- void
- push (T& t)
- {
- seq_.push_back (T());
- operator[](0).move (t);
- }
-
- void
- pop (unsigned n = 1)
- {
- for (; n; --n)
- seq_.pop_back ();
- }
-
- void
- clear ()
- {
- seq_.clear ();
- }
-
- typename S::size_type
- size () const
- {
- return seq_.size ();
- }
-
- const_iterator
- begin () const
- {
- return seq_.rbegin ();
- }
-
- const_iterator
- end () const
- {
- return seq_.rend ();
- }
-
- private:
- stack (const stack&);
- stack& operator= (const stack&);
- /// The wrapped container.
- S seq_;
- };
-
- /// Present a slice of the top of a stack.
- template <class T, class S = stack<T> >
- class slice
- {
- public:
- slice (const S& stack, unsigned range)
- : stack_ (stack)
- , range_ (range)
- {}
-
- const T&
- operator [] (unsigned i) const
- {
- return stack_[range_ - i];
- }
-
- private:
- const S& stack_;
- unsigned range_;
- };
-
-#line 14 "parser.yy" // stack.hh:131
-} } // isc::eval
-#line 155 "stack.hh" // stack.hh:131
-
-#endif // !YY_EVAL_STACK_HH_INCLUDED
+// Generated 201811172152
+// A Bison parser, made by GNU Bison 3.2.1.
+
+// Starting with Bison 3.2, this file is useless: the structure it
+// used to define is now defined with the parser itself.
+//
+// To get rid of this file:
+// 1. add 'require "3.2"' (or newer) to your grammar file
+// 2. remove references to this file from your build system.