-Grammar generated on 2021-06-22 19:06. See Chapter :ref:`kea-ctrl-agent` for an explanation.
+Grammar generated on 2021-12-14 13:12. See Chapter :ref:`kea-ctrl-agent` for an explanation.
.. code-block:: BNF
:linenos:
-Grammar generated on 2021-06-22 19:06. See Chapter :ref:`dhcp-ddns-server` for an explanation.
+Grammar generated on 2021-12-14 13:12. See Chapter :ref:`dhcp-ddns-server` for an explanation.
.. code-block:: BNF
:linenos:
| ddns_domain_params "," ddns_domain_param
ddns_domain_param ::= ddns_domain_name
- | ddns_domain_key_name
+ | ddns_key_name
| dns_servers
| user_context
| comment
ddns_domain_name ::= "name" ":" STRING
- ddns_domain_key_name ::= "key-name" ":" STRING
+ ddns_key_name ::= "key-name" ":" STRING
dns_servers ::= "dns-servers" ":" "[" dns_server_list "]"
dns_server_param ::= dns_server_hostname
| dns_server_ip_address
| dns_server_port
+ | ddns_key_name
| user_context
| comment
| unknown_map_entry
-Grammar generated on 2021-06-22 19:06. See Chapter :ref:`dhcp4` for an explanation.
+Grammar generated on 2021-12-14 13:12. See Chapter :ref:`dhcp4` for an explanation.
.. code-block:: BNF
:linenos:
| dhcp_multi_threading
| ip_reservations_unique
| compatibility
+ | parked_packet_limit
| unknown_map_entry
valid_lifetime ::= "valid-lifetime" ":" INTEGER
server_tag ::= "server-tag" ":" STRING
+ parked_packet_limit ::= "parked-packet-limit" ":" INTEGER
+
echo_client_id ::= "echo-client-id" ":" BOOLEAN
match_client_id ::= "match-client-id" ":" BOOLEAN
-Grammar generated on 2021-06-22 19:06. See Chapter :ref:`dhcp6` for an explanation.
+Grammar generated on 2021-12-14 13:12. See Chapter :ref:`dhcp6` for an explanation.
.. code-block:: BNF
:linenos:
| dhcp_multi_threading
| ip_reservations_unique
| compatibility
+ | parked_packet_limit
| unknown_map_entry
data_directory ::= "data-directory" ":" STRING
server_tag ::= "server-tag" ":" STRING
+ parked_packet_limit ::= "parked-packet-limit" ":" INTEGER
+
ip_reservations_unique ::= "ip-reservations-unique" ":" BOOLEAN
interfaces_config ::= "interfaces-config" ":" "{" interfaces_config_params "}"
| option_data_list
| user_context
| comment
+ | preferred_lifetime
+ | min_preferred_lifetime
+ | max_preferred_lifetime
+ | valid_lifetime
+ | min_valid_lifetime
+ | max_valid_lifetime
| unknown_map_entry
client_class_name ::= name
-Grammar generated on 2021-06-22 19:06. See Chapter :ref:`netconf` for an explanation.
+Grammar generated on 2021-12-14 13:12. See Chapter :ref:`netconf` for an explanation.
.. code-block:: BNF
:linenos:
-// A Bison parser, made by GNU Bison 3.7.6.
+// A Bison parser, made by GNU Bison 3.8.2.
// Skeleton implementation for Bison LALR(1) parsers in C++
AgentParser::syntax_error::~syntax_error () YY_NOEXCEPT YY_NOTHROW
{}
- /*---------------.
- | symbol kinds. |
- `---------------*/
+ /*---------.
+ | symbol. |
+ `---------*/
}
void
- AgentParser::yypop_ (int n)
+ AgentParser::yypop_ (int n) YY_NOEXCEPT
{
yystack_.pop (n);
}
}
bool
- AgentParser::yy_pact_value_is_default_ (int yyvalue)
+ AgentParser::yy_pact_value_is_default_ (int yyvalue) YY_NOEXCEPT
{
return yyvalue == yypact_ninf_;
}
bool
- AgentParser::yy_table_value_is_error_ (int yyvalue)
+ AgentParser::yy_table_value_is_error_ (int yyvalue) YY_NOEXCEPT
{
return yyvalue == yytable_ninf_;
}
// Actual number of expected tokens
int yycount = 0;
- int yyn = yypact_[+yyparser_.yystack_[0].state];
+ const int yyn = yypact_[+yyparser_.yystack_[0].state];
if (!yy_pact_value_is_default_ (yyn))
{
/* Start YYX at -YYN if negative to avoid negative indexes in
YYCHECK. In other words, skip the first -YYN actions for
this state because they are default actions. */
- int yyxbegin = yyn < 0 ? -yyn : 0;
+ const int yyxbegin = yyn < 0 ? -yyn : 0;
// Stay within bounds of both yycheck and yytname.
- int yychecklim = yylast_ - yyn + 1;
- int yyxend = yychecklim < YYNTOKENS ? yychecklim : YYNTOKENS;
+ const int yychecklim = yylast_ - yyn + 1;
+ const int yyxend = yychecklim < YYNTOKENS ? yychecklim : YYNTOKENS;
for (int yyx = yyxbegin; yyx < yyxend; ++yyx)
if (yycheck_[yyx + yyn] == yyx && yyx != symbol_kind::S_YYerror
&& !yy_table_value_is_error_ (yytable_[yyx + yyn]))
+
+
+
int
AgentParser::yy_syntax_error_arguments_ (const context& yyctx,
symbol_kind_type yyarg[], int yyargn) const
#line 14 "agent_parser.yy"
} } // isc::agent
-#line 2344 "agent_parser.cc"
+#line 2347 "agent_parser.cc"
#line 782 "agent_parser.yy"
-// A Bison parser, made by GNU Bison 3.7.6.
+// A Bison parser, made by GNU Bison 3.8.2.
// Skeleton interface for Bison LALR(1) parsers in C++
# define YY_USE(E) /* empty */
#endif
-#if defined __GNUC__ && ! defined __ICC && 407 <= __GNUC__ * 100 + __GNUC_MINOR__
/* Suppress an incorrect diagnostic about yylval being uninitialized. */
-# define YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN \
+#if defined __GNUC__ && ! defined __ICC && 406 <= __GNUC__ * 100 + __GNUC_MINOR__
+# if __GNUC__ * 100 + __GNUC_MINOR__ < 407
+# define YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN \
+ _Pragma ("GCC diagnostic push") \
+ _Pragma ("GCC diagnostic ignored \"-Wuninitialized\"")
+# else
+# define YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN \
_Pragma ("GCC diagnostic push") \
_Pragma ("GCC diagnostic ignored \"-Wuninitialized\"") \
_Pragma ("GCC diagnostic ignored \"-Wmaybe-uninitialized\"")
+# endif
# define YY_IGNORE_MAYBE_UNINITIALIZED_END \
_Pragma ("GCC diagnostic pop")
#else
#line 14 "agent_parser.yy"
namespace isc { namespace agent {
-#line 203 "agent_parser.h"
+#line 209 "agent_parser.h"
class AgentParser
{
public:
-#ifndef AGENT_STYPE
+#ifdef AGENT_STYPE
+# ifdef __GNUC__
+# pragma GCC message "bison: do not #define AGENT_STYPE in C++, use %define api.value.type"
+# endif
+ typedef AGENT_STYPE value_type;
+#else
/// A buffer to store and retrieve objects.
///
/// Sort of a variant, but does not keep track of the nature
/// of the stored data, since that knowledge is available
/// via the current parser state.
- class semantic_type
+ class value_type
{
public:
/// Type of *this.
- typedef semantic_type self_type;
+ typedef value_type self_type;
/// Empty construction.
- semantic_type () YY_NOEXCEPT
- : yybuffer_ ()
+ value_type () YY_NOEXCEPT
+ : yyraw_ ()
, yytypeid_ (YY_NULLPTR)
{}
/// Construct and fill.
template <typename T>
- semantic_type (YY_RVREF (T) t)
+ value_type (YY_RVREF (T) t)
: yytypeid_ (&typeid (T))
{
AGENT__ASSERT (sizeof (T) <= size);
#if 201103L <= YY_CPLUSPLUS
/// Non copyable.
- semantic_type (const self_type&) = delete;
+ value_type (const self_type&) = delete;
/// Non copyable.
self_type& operator= (const self_type&) = delete;
#endif
/// Destruction, allowed only if empty.
- ~semantic_type () YY_NOEXCEPT
+ ~value_type () YY_NOEXCEPT
{
AGENT__ASSERT (!yytypeid_);
}
private:
#if YY_CPLUSPLUS < 201103L
/// Non copyable.
- semantic_type (const self_type&);
+ value_type (const self_type&);
/// Non copyable.
self_type& operator= (const self_type&);
#endif
T*
yyas_ () YY_NOEXCEPT
{
- void *yyp = yybuffer_.yyraw;
+ void *yyp = yyraw_;
return static_cast<T*> (yyp);
}
const T*
yyas_ () const YY_NOEXCEPT
{
- const void *yyp = yybuffer_.yyraw;
+ const void *yyp = yyraw_;
return static_cast<const T*> (yyp);
}
union
{
/// Strongest alignment constraints.
- long double yyalign_me;
+ long double yyalign_me_;
/// A buffer large enough to store any of the semantic values.
- char yyraw[size];
- } yybuffer_;
+ char yyraw_[size];
+ };
/// Whether the content is built: if defined, the name of the stored type.
const std::type_info *yytypeid_;
};
-#else
- typedef AGENT_STYPE semantic_type;
#endif
+ /// Backward compatibility (Bison 3.8).
+ typedef value_type semantic_type;
+
/// Symbol locations.
typedef location location_type;
};
/// Token kind, as returned by yylex.
- typedef token::yytokentype token_kind_type;
+ typedef token::token_kind_type token_kind_type;
/// Backward compatibility alias (Bison 3.6).
typedef token_kind_type token_type;
typedef Base super_type;
/// Default constructor.
- basic_symbol ()
+ basic_symbol () YY_NOEXCEPT
: value ()
, location ()
{}
clear ();
}
+
+
/// Destroy contents, and record that is empty.
void clear () YY_NOEXCEPT
{
void move (basic_symbol& s);
/// The semantic value.
- semantic_type value;
+ value_type value;
/// The location.
location_type location;
/// Type access provider for token (enum) based symbols.
struct by_kind
{
+ /// The symbol kind as needed by the constructor.
+ typedef token_kind_type kind_type;
+
/// Default constructor.
- by_kind ();
+ by_kind () YY_NOEXCEPT;
#if 201103L <= YY_CPLUSPLUS
/// Move constructor.
- by_kind (by_kind&& that);
+ by_kind (by_kind&& that) YY_NOEXCEPT;
#endif
/// Copy constructor.
- by_kind (const by_kind& that);
-
- /// The symbol kind as needed by the constructor.
- typedef token_kind_type kind_type;
+ by_kind (const by_kind& that) YY_NOEXCEPT;
/// Constructor from (external) token numbers.
- by_kind (kind_type t);
+ by_kind (kind_type t) YY_NOEXCEPT;
+
+
/// Record that this symbol is empty.
void clear () YY_NOEXCEPT;
typedef basic_symbol<by_kind> super_type;
/// Empty symbol.
- symbol_type () {}
+ symbol_type () YY_NOEXCEPT {}
/// Constructor for valueless symbols, and symbols from each type.
#if 201103L <= YY_CPLUSPLUS
symbol_type (int tok, location_type l)
- : super_type(token_type (tok), std::move (l))
+ : super_type (token_kind_type (tok), std::move (l))
#else
symbol_type (int tok, const location_type& l)
- : super_type(token_type (tok), l)
+ : super_type (token_kind_type (tok), l)
#endif
{
+#if !defined _MSC_VER || defined __clang__
AGENT__ASSERT (tok == token::TOKEN_END
|| (token::TOKEN_AGENT_error <= tok && tok <= token::TOKEN_START_SUB_AGENT));
+#endif
}
#if 201103L <= YY_CPLUSPLUS
symbol_type (int tok, bool v, location_type l)
- : super_type(token_type (tok), std::move (v), std::move (l))
+ : super_type (token_kind_type (tok), std::move (v), std::move (l))
#else
symbol_type (int tok, const bool& v, const location_type& l)
- : super_type(token_type (tok), v, l)
+ : super_type (token_kind_type (tok), v, l)
#endif
{
+#if !defined _MSC_VER || defined __clang__
AGENT__ASSERT (tok == token::TOKEN_BOOLEAN);
+#endif
}
#if 201103L <= YY_CPLUSPLUS
symbol_type (int tok, double v, location_type l)
- : super_type(token_type (tok), std::move (v), std::move (l))
+ : super_type (token_kind_type (tok), std::move (v), std::move (l))
#else
symbol_type (int tok, const double& v, const location_type& l)
- : super_type(token_type (tok), v, l)
+ : super_type (token_kind_type (tok), v, l)
#endif
{
+#if !defined _MSC_VER || defined __clang__
AGENT__ASSERT (tok == token::TOKEN_FLOAT);
+#endif
}
#if 201103L <= YY_CPLUSPLUS
symbol_type (int tok, int64_t v, location_type l)
- : super_type(token_type (tok), std::move (v), std::move (l))
+ : super_type (token_kind_type (tok), std::move (v), std::move (l))
#else
symbol_type (int tok, const int64_t& v, const location_type& l)
- : super_type(token_type (tok), v, l)
+ : super_type (token_kind_type (tok), v, l)
#endif
{
+#if !defined _MSC_VER || defined __clang__
AGENT__ASSERT (tok == token::TOKEN_INTEGER);
+#endif
}
#if 201103L <= YY_CPLUSPLUS
symbol_type (int tok, std::string v, location_type l)
- : super_type(token_type (tok), std::move (v), std::move (l))
+ : super_type (token_kind_type (tok), std::move (v), std::move (l))
#else
symbol_type (int tok, const std::string& v, const location_type& l)
- : super_type(token_type (tok), v, l)
+ : super_type (token_kind_type (tok), v, l)
#endif
{
+#if !defined _MSC_VER || defined __clang__
AGENT__ASSERT (tok == token::TOKEN_STRING);
+#endif
}
};
/// YYSYMBOL. No bounds checking.
static std::string symbol_name (symbol_kind_type yysymbol);
- // Implementation of make_symbol for each symbol type.
+ // Implementation of make_symbol for each token kind.
#if 201103L <= YY_CPLUSPLUS
static
symbol_type
/// Whether the given \c yypact_ value indicates a defaulted state.
/// \param yyvalue the value to check
- static bool yy_pact_value_is_default_ (int yyvalue);
+ static bool yy_pact_value_is_default_ (int yyvalue) YY_NOEXCEPT;
/// Whether the given \c yytable_ value indicates a syntax error.
/// \param yyvalue the value to check
- static bool yy_table_value_is_error_ (int yyvalue);
+ static bool yy_table_value_is_error_ (int yyvalue) YY_NOEXCEPT;
static const short yypact_ninf_;
static const signed char yytable_ninf_;
/// Convert a scanner token kind \a t to a symbol kind.
/// In theory \a t should be a token_kind_type, but character literals
- /// are valid, yet not members of the token_type enum.
- static symbol_kind_type yytranslate_ (int t);
+ /// are valid, yet not members of the token_kind_type enum.
+ static symbol_kind_type yytranslate_ (int t) YY_NOEXCEPT;
/// Convert the symbol name \a n to a form suitable for a diagnostic.
static std::string yytnamerr_ (const char *yystr);
static const short yycheck_[];
- // YYSTOS[STATE-NUM] -- The (internal number of the) accessing
- // symbol of state STATE-NUM.
+ // YYSTOS[STATE-NUM] -- The symbol kind of the accessing symbol of
+ // state STATE-NUM.
static const unsigned char yystos_[];
- // YYR1[YYN] -- Symbol number of symbol that rule YYN derives.
+ // YYR1[RULE-NUM] -- Symbol kind of the left-hand side of rule RULE-NUM.
static const unsigned char yyr1_[];
- // YYR2[YYN] -- Number of symbols on the right hand side of rule YYN.
+ // YYR2[RULE-NUM] -- Number of symbols on the right-hand side of rule RULE-NUM.
static const signed char yyr2_[];
typedef typename S::size_type size_type;
typedef typename std::ptrdiff_t index_type;
- stack (size_type n = 200)
+ stack (size_type n = 200) YY_NOEXCEPT
: seq_ (n)
{}
class slice
{
public:
- slice (const stack& stack, index_type range)
+ slice (const stack& stack, index_type range) YY_NOEXCEPT
: stack_ (stack)
, range_ (range)
{}
void yypush_ (const char* m, state_type s, YY_MOVE_REF (symbol_type) sym);
/// Pop \a n symbols from the stack.
- void yypop_ (int n = 1);
+ void yypop_ (int n = 1) YY_NOEXCEPT;
/// Constants.
enum
inline
AgentParser::symbol_kind_type
- AgentParser::yytranslate_ (int t)
+ AgentParser::yytranslate_ (int t) YY_NOEXCEPT
{
// YYTRANSLATE[TOKEN-NUM] -- Symbol number corresponding to
// TOKEN-NUM as returned by yylex.
if (t <= 0)
return symbol_kind::S_YYEOF;
else if (t <= code_max)
- return YY_CAST (symbol_kind_type, translate_table[t]);
+ return static_cast <symbol_kind_type> (translate_table[t]);
else
return symbol_kind::S_YYUNDEF;
}
+
template <typename Base>
AgentParser::symbol_kind_type
AgentParser::basic_symbol<Base>::type_get () const YY_NOEXCEPT
return this->kind ();
}
+
template <typename Base>
bool
AgentParser::basic_symbol<Base>::empty () const YY_NOEXCEPT
// by_kind.
inline
- AgentParser::by_kind::by_kind ()
+ AgentParser::by_kind::by_kind () YY_NOEXCEPT
: kind_ (symbol_kind::S_YYEMPTY)
{}
#if 201103L <= YY_CPLUSPLUS
inline
- AgentParser::by_kind::by_kind (by_kind&& that)
+ AgentParser::by_kind::by_kind (by_kind&& that) YY_NOEXCEPT
: kind_ (that.kind_)
{
that.clear ();
#endif
inline
- AgentParser::by_kind::by_kind (const by_kind& that)
+ AgentParser::by_kind::by_kind (const by_kind& that) YY_NOEXCEPT
: kind_ (that.kind_)
{}
inline
- AgentParser::by_kind::by_kind (token_kind_type t)
+ AgentParser::by_kind::by_kind (token_kind_type t) YY_NOEXCEPT
: kind_ (yytranslate_ (t))
{}
+
+
inline
void
AgentParser::by_kind::clear () YY_NOEXCEPT
return kind_;
}
+
inline
AgentParser::symbol_kind_type
AgentParser::by_kind::type_get () const YY_NOEXCEPT
return this->kind ();
}
+
#line 14 "agent_parser.yy"
} } // isc::agent
-#line 2439 "agent_parser.h"
+#line 2471 "agent_parser.h"
-// A Bison parser, made by GNU Bison 3.7.6.
+// A Bison parser, made by GNU Bison 3.8.2.
// Locations for Bison parsers in C++
-// A Bison parser, made by GNU Bison 3.7.6.
+// A Bison parser, made by GNU Bison 3.8.2.
// Skeleton implementation for Bison LALR(1) parsers in C++
D2Parser::syntax_error::~syntax_error () YY_NOEXCEPT YY_NOTHROW
{}
- /*---------------.
- | symbol kinds. |
- `---------------*/
+ /*---------.
+ | symbol. |
+ `---------*/
}
void
- D2Parser::yypop_ (int n)
+ D2Parser::yypop_ (int n) YY_NOEXCEPT
{
yystack_.pop (n);
}
}
bool
- D2Parser::yy_pact_value_is_default_ (int yyvalue)
+ D2Parser::yy_pact_value_is_default_ (int yyvalue) YY_NOEXCEPT
{
return yyvalue == yypact_ninf_;
}
bool
- D2Parser::yy_table_value_is_error_ (int yyvalue)
+ D2Parser::yy_table_value_is_error_ (int yyvalue) YY_NOEXCEPT
{
return yyvalue == yytable_ninf_;
}
// Actual number of expected tokens
int yycount = 0;
- int yyn = yypact_[+yyparser_.yystack_[0].state];
+ const int yyn = yypact_[+yyparser_.yystack_[0].state];
if (!yy_pact_value_is_default_ (yyn))
{
/* Start YYX at -YYN if negative to avoid negative indexes in
YYCHECK. In other words, skip the first -YYN actions for
this state because they are default actions. */
- int yyxbegin = yyn < 0 ? -yyn : 0;
+ const int yyxbegin = yyn < 0 ? -yyn : 0;
// Stay within bounds of both yycheck and yytname.
- int yychecklim = yylast_ - yyn + 1;
- int yyxend = yychecklim < YYNTOKENS ? yychecklim : YYNTOKENS;
+ const int yychecklim = yylast_ - yyn + 1;
+ const int yyxend = yychecklim < YYNTOKENS ? yychecklim : YYNTOKENS;
for (int yyx = yyxbegin; yyx < yyxend; ++yyx)
if (yycheck_[yyx + yyn] == yyx && yyx != symbol_kind::S_YYerror
&& !yy_table_value_is_error_ (yytable_[yyx + yyn]))
+
+
+
int
D2Parser::yy_syntax_error_arguments_ (const context& yyctx,
symbol_kind_type yyarg[], int yyargn) const
#line 14 "d2_parser.yy"
} } // isc::d2
-#line 2695 "d2_parser.cc"
+#line 2698 "d2_parser.cc"
#line 929 "d2_parser.yy"
-// A Bison parser, made by GNU Bison 3.7.6.
+// A Bison parser, made by GNU Bison 3.8.2.
// Skeleton interface for Bison LALR(1) parsers in C++
# define YY_USE(E) /* empty */
#endif
-#if defined __GNUC__ && ! defined __ICC && 407 <= __GNUC__ * 100 + __GNUC_MINOR__
/* Suppress an incorrect diagnostic about yylval being uninitialized. */
-# define YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN \
+#if defined __GNUC__ && ! defined __ICC && 406 <= __GNUC__ * 100 + __GNUC_MINOR__
+# if __GNUC__ * 100 + __GNUC_MINOR__ < 407
+# define YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN \
+ _Pragma ("GCC diagnostic push") \
+ _Pragma ("GCC diagnostic ignored \"-Wuninitialized\"")
+# else
+# define YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN \
_Pragma ("GCC diagnostic push") \
_Pragma ("GCC diagnostic ignored \"-Wuninitialized\"") \
_Pragma ("GCC diagnostic ignored \"-Wmaybe-uninitialized\"")
+# endif
# define YY_IGNORE_MAYBE_UNINITIALIZED_END \
_Pragma ("GCC diagnostic pop")
#else
#line 14 "d2_parser.yy"
namespace isc { namespace d2 {
-#line 204 "d2_parser.h"
+#line 210 "d2_parser.h"
class D2Parser
{
public:
-#ifndef D2_PARSER_STYPE
+#ifdef D2_PARSER_STYPE
+# ifdef __GNUC__
+# pragma GCC message "bison: do not #define D2_PARSER_STYPE in C++, use %define api.value.type"
+# endif
+ typedef D2_PARSER_STYPE value_type;
+#else
/// A buffer to store and retrieve objects.
///
/// Sort of a variant, but does not keep track of the nature
/// of the stored data, since that knowledge is available
/// via the current parser state.
- class semantic_type
+ class value_type
{
public:
/// Type of *this.
- typedef semantic_type self_type;
+ typedef value_type self_type;
/// Empty construction.
- semantic_type () YY_NOEXCEPT
- : yybuffer_ ()
+ value_type () YY_NOEXCEPT
+ : yyraw_ ()
, yytypeid_ (YY_NULLPTR)
{}
/// Construct and fill.
template <typename T>
- semantic_type (YY_RVREF (T) t)
+ value_type (YY_RVREF (T) t)
: yytypeid_ (&typeid (T))
{
D2_PARSER__ASSERT (sizeof (T) <= size);
#if 201103L <= YY_CPLUSPLUS
/// Non copyable.
- semantic_type (const self_type&) = delete;
+ value_type (const self_type&) = delete;
/// Non copyable.
self_type& operator= (const self_type&) = delete;
#endif
/// Destruction, allowed only if empty.
- ~semantic_type () YY_NOEXCEPT
+ ~value_type () YY_NOEXCEPT
{
D2_PARSER__ASSERT (!yytypeid_);
}
private:
#if YY_CPLUSPLUS < 201103L
/// Non copyable.
- semantic_type (const self_type&);
+ value_type (const self_type&);
/// Non copyable.
self_type& operator= (const self_type&);
#endif
T*
yyas_ () YY_NOEXCEPT
{
- void *yyp = yybuffer_.yyraw;
+ void *yyp = yyraw_;
return static_cast<T*> (yyp);
}
const T*
yyas_ () const YY_NOEXCEPT
{
- const void *yyp = yybuffer_.yyraw;
+ const void *yyp = yyraw_;
return static_cast<const T*> (yyp);
}
union
{
/// Strongest alignment constraints.
- long double yyalign_me;
+ long double yyalign_me_;
/// A buffer large enough to store any of the semantic values.
- char yyraw[size];
- } yybuffer_;
+ char yyraw_[size];
+ };
/// Whether the content is built: if defined, the name of the stored type.
const std::type_info *yytypeid_;
};
-#else
- typedef D2_PARSER_STYPE semantic_type;
#endif
+ /// Backward compatibility (Bison 3.8).
+ typedef value_type semantic_type;
+
/// Symbol locations.
typedef location location_type;
};
/// Token kind, as returned by yylex.
- typedef token::yytokentype token_kind_type;
+ typedef token::token_kind_type token_kind_type;
/// Backward compatibility alias (Bison 3.6).
typedef token_kind_type token_type;
typedef Base super_type;
/// Default constructor.
- basic_symbol ()
+ basic_symbol () YY_NOEXCEPT
: value ()
, location ()
{}
clear ();
}
+
+
/// Destroy contents, and record that is empty.
void clear () YY_NOEXCEPT
{
void move (basic_symbol& s);
/// The semantic value.
- semantic_type value;
+ value_type value;
/// The location.
location_type location;
/// Type access provider for token (enum) based symbols.
struct by_kind
{
+ /// The symbol kind as needed by the constructor.
+ typedef token_kind_type kind_type;
+
/// Default constructor.
- by_kind ();
+ by_kind () YY_NOEXCEPT;
#if 201103L <= YY_CPLUSPLUS
/// Move constructor.
- by_kind (by_kind&& that);
+ by_kind (by_kind&& that) YY_NOEXCEPT;
#endif
/// Copy constructor.
- by_kind (const by_kind& that);
-
- /// The symbol kind as needed by the constructor.
- typedef token_kind_type kind_type;
+ by_kind (const by_kind& that) YY_NOEXCEPT;
/// Constructor from (external) token numbers.
- by_kind (kind_type t);
+ by_kind (kind_type t) YY_NOEXCEPT;
+
+
/// Record that this symbol is empty.
void clear () YY_NOEXCEPT;
typedef basic_symbol<by_kind> super_type;
/// Empty symbol.
- symbol_type () {}
+ symbol_type () YY_NOEXCEPT {}
/// Constructor for valueless symbols, and symbols from each type.
#if 201103L <= YY_CPLUSPLUS
symbol_type (int tok, location_type l)
- : super_type(token_type (tok), std::move (l))
+ : super_type (token_kind_type (tok), std::move (l))
#else
symbol_type (int tok, const location_type& l)
- : super_type(token_type (tok), l)
+ : super_type (token_kind_type (tok), l)
#endif
{
+#if !defined _MSC_VER || defined __clang__
D2_PARSER__ASSERT (tok == token::TOKEN_END
|| (token::TOKEN_D2_PARSER_error <= tok && tok <= token::TOKEN_SUB_HOOKS_LIBRARY));
+#endif
}
#if 201103L <= YY_CPLUSPLUS
symbol_type (int tok, bool v, location_type l)
- : super_type(token_type (tok), std::move (v), std::move (l))
+ : super_type (token_kind_type (tok), std::move (v), std::move (l))
#else
symbol_type (int tok, const bool& v, const location_type& l)
- : super_type(token_type (tok), v, l)
+ : super_type (token_kind_type (tok), v, l)
#endif
{
+#if !defined _MSC_VER || defined __clang__
D2_PARSER__ASSERT (tok == token::TOKEN_BOOLEAN);
+#endif
}
#if 201103L <= YY_CPLUSPLUS
symbol_type (int tok, double v, location_type l)
- : super_type(token_type (tok), std::move (v), std::move (l))
+ : super_type (token_kind_type (tok), std::move (v), std::move (l))
#else
symbol_type (int tok, const double& v, const location_type& l)
- : super_type(token_type (tok), v, l)
+ : super_type (token_kind_type (tok), v, l)
#endif
{
+#if !defined _MSC_VER || defined __clang__
D2_PARSER__ASSERT (tok == token::TOKEN_FLOAT);
+#endif
}
#if 201103L <= YY_CPLUSPLUS
symbol_type (int tok, int64_t v, location_type l)
- : super_type(token_type (tok), std::move (v), std::move (l))
+ : super_type (token_kind_type (tok), std::move (v), std::move (l))
#else
symbol_type (int tok, const int64_t& v, const location_type& l)
- : super_type(token_type (tok), v, l)
+ : super_type (token_kind_type (tok), v, l)
#endif
{
+#if !defined _MSC_VER || defined __clang__
D2_PARSER__ASSERT (tok == token::TOKEN_INTEGER);
+#endif
}
#if 201103L <= YY_CPLUSPLUS
symbol_type (int tok, std::string v, location_type l)
- : super_type(token_type (tok), std::move (v), std::move (l))
+ : super_type (token_kind_type (tok), std::move (v), std::move (l))
#else
symbol_type (int tok, const std::string& v, const location_type& l)
- : super_type(token_type (tok), v, l)
+ : super_type (token_kind_type (tok), v, l)
#endif
{
+#if !defined _MSC_VER || defined __clang__
D2_PARSER__ASSERT (tok == token::TOKEN_STRING);
+#endif
}
};
/// YYSYMBOL. No bounds checking.
static std::string symbol_name (symbol_kind_type yysymbol);
- // Implementation of make_symbol for each symbol type.
+ // Implementation of make_symbol for each token kind.
#if 201103L <= YY_CPLUSPLUS
static
symbol_type
/// Whether the given \c yypact_ value indicates a defaulted state.
/// \param yyvalue the value to check
- static bool yy_pact_value_is_default_ (int yyvalue);
+ static bool yy_pact_value_is_default_ (int yyvalue) YY_NOEXCEPT;
/// Whether the given \c yytable_ value indicates a syntax error.
/// \param yyvalue the value to check
- static bool yy_table_value_is_error_ (int yyvalue);
+ static bool yy_table_value_is_error_ (int yyvalue) YY_NOEXCEPT;
static const short yypact_ninf_;
static const signed char yytable_ninf_;
/// Convert a scanner token kind \a t to a symbol kind.
/// In theory \a t should be a token_kind_type, but character literals
- /// are valid, yet not members of the token_type enum.
- static symbol_kind_type yytranslate_ (int t);
+ /// are valid, yet not members of the token_kind_type enum.
+ static symbol_kind_type yytranslate_ (int t) YY_NOEXCEPT;
/// Convert the symbol name \a n to a form suitable for a diagnostic.
static std::string yytnamerr_ (const char *yystr);
static const short yycheck_[];
- // YYSTOS[STATE-NUM] -- The (internal number of the) accessing
- // symbol of state STATE-NUM.
+ // YYSTOS[STATE-NUM] -- The symbol kind of the accessing symbol of
+ // state STATE-NUM.
static const unsigned char yystos_[];
- // YYR1[YYN] -- Symbol number of symbol that rule YYN derives.
+ // YYR1[RULE-NUM] -- Symbol kind of the left-hand side of rule RULE-NUM.
static const unsigned char yyr1_[];
- // YYR2[YYN] -- Number of symbols on the right hand side of rule YYN.
+ // YYR2[RULE-NUM] -- Number of symbols on the right-hand side of rule RULE-NUM.
static const signed char yyr2_[];
typedef typename S::size_type size_type;
typedef typename std::ptrdiff_t index_type;
- stack (size_type n = 200)
+ stack (size_type n = 200) YY_NOEXCEPT
: seq_ (n)
{}
class slice
{
public:
- slice (const stack& stack, index_type range)
+ slice (const stack& stack, index_type range) YY_NOEXCEPT
: stack_ (stack)
, range_ (range)
{}
void yypush_ (const char* m, state_type s, YY_MOVE_REF (symbol_type) sym);
/// Pop \a n symbols from the stack.
- void yypop_ (int n = 1);
+ void yypop_ (int n = 1) YY_NOEXCEPT;
/// Constants.
enum
inline
D2Parser::symbol_kind_type
- D2Parser::yytranslate_ (int t)
+ D2Parser::yytranslate_ (int t) YY_NOEXCEPT
{
// YYTRANSLATE[TOKEN-NUM] -- Symbol number corresponding to
// TOKEN-NUM as returned by yylex.
if (t <= 0)
return symbol_kind::S_YYEOF;
else if (t <= code_max)
- return YY_CAST (symbol_kind_type, translate_table[t]);
+ return static_cast <symbol_kind_type> (translate_table[t]);
else
return symbol_kind::S_YYUNDEF;
}
+
template <typename Base>
D2Parser::symbol_kind_type
D2Parser::basic_symbol<Base>::type_get () const YY_NOEXCEPT
return this->kind ();
}
+
template <typename Base>
bool
D2Parser::basic_symbol<Base>::empty () const YY_NOEXCEPT
// by_kind.
inline
- D2Parser::by_kind::by_kind ()
+ D2Parser::by_kind::by_kind () YY_NOEXCEPT
: kind_ (symbol_kind::S_YYEMPTY)
{}
#if 201103L <= YY_CPLUSPLUS
inline
- D2Parser::by_kind::by_kind (by_kind&& that)
+ D2Parser::by_kind::by_kind (by_kind&& that) YY_NOEXCEPT
: kind_ (that.kind_)
{
that.clear ();
#endif
inline
- D2Parser::by_kind::by_kind (const by_kind& that)
+ D2Parser::by_kind::by_kind (const by_kind& that) YY_NOEXCEPT
: kind_ (that.kind_)
{}
inline
- D2Parser::by_kind::by_kind (token_kind_type t)
+ D2Parser::by_kind::by_kind (token_kind_type t) YY_NOEXCEPT
: kind_ (yytranslate_ (t))
{}
+
+
inline
void
D2Parser::by_kind::clear () YY_NOEXCEPT
return kind_;
}
+
inline
D2Parser::symbol_kind_type
D2Parser::by_kind::type_get () const YY_NOEXCEPT
return this->kind ();
}
+
#line 14 "d2_parser.yy"
} } // isc::d2
-#line 2608 "d2_parser.h"
+#line 2640 "d2_parser.h"
-// A Bison parser, made by GNU Bison 3.7.6.
+// A Bison parser, made by GNU Bison 3.8.2.
// Locations for Bison parsers in C++
-// A Bison parser, made by GNU Bison 3.7.6.
+// A Bison parser, made by GNU Bison 3.8.2.
// Skeleton implementation for Bison LALR(1) parsers in C++
Dhcp4Parser::syntax_error::~syntax_error () YY_NOEXCEPT YY_NOTHROW
{}
- /*---------------.
- | symbol kinds. |
- `---------------*/
+ /*---------.
+ | symbol. |
+ `---------*/
}
void
- Dhcp4Parser::yypop_ (int n)
+ Dhcp4Parser::yypop_ (int n) YY_NOEXCEPT
{
yystack_.pop (n);
}
}
bool
- Dhcp4Parser::yy_pact_value_is_default_ (int yyvalue)
+ Dhcp4Parser::yy_pact_value_is_default_ (int yyvalue) YY_NOEXCEPT
{
return yyvalue == yypact_ninf_;
}
bool
- Dhcp4Parser::yy_table_value_is_error_ (int yyvalue)
+ Dhcp4Parser::yy_table_value_is_error_ (int yyvalue) YY_NOEXCEPT
{
return yyvalue == yytable_ninf_;
}
// Actual number of expected tokens
int yycount = 0;
- int yyn = yypact_[+yyparser_.yystack_[0].state];
+ const int yyn = yypact_[+yyparser_.yystack_[0].state];
if (!yy_pact_value_is_default_ (yyn))
{
/* Start YYX at -YYN if negative to avoid negative indexes in
YYCHECK. In other words, skip the first -YYN actions for
this state because they are default actions. */
- int yyxbegin = yyn < 0 ? -yyn : 0;
+ const int yyxbegin = yyn < 0 ? -yyn : 0;
// Stay within bounds of both yycheck and yytname.
- int yychecklim = yylast_ - yyn + 1;
- int yyxend = yychecklim < YYNTOKENS ? yychecklim : YYNTOKENS;
+ const int yychecklim = yylast_ - yyn + 1;
+ const int yyxend = yychecklim < YYNTOKENS ? yychecklim : YYNTOKENS;
for (int yyx = yyxbegin; yyx < yyxend; ++yyx)
if (yycheck_[yyx + yyn] == yyx && yyx != symbol_kind::S_YYerror
&& !yy_table_value_is_error_ (yytable_[yyx + yyn]))
+
+
+
int
Dhcp4Parser::yy_syntax_error_arguments_ (const context& yyctx,
symbol_kind_type yyarg[], int yyargn) const
#line 14 "dhcp4_parser.yy"
} } // isc::dhcp
-#line 5837 "dhcp4_parser.cc"
+#line 5840 "dhcp4_parser.cc"
#line 2732 "dhcp4_parser.yy"
-// A Bison parser, made by GNU Bison 3.7.6.
+// A Bison parser, made by GNU Bison 3.8.2.
// Skeleton interface for Bison LALR(1) parsers in C++
# define YY_USE(E) /* empty */
#endif
-#if defined __GNUC__ && ! defined __ICC && 407 <= __GNUC__ * 100 + __GNUC_MINOR__
/* Suppress an incorrect diagnostic about yylval being uninitialized. */
-# define YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN \
+#if defined __GNUC__ && ! defined __ICC && 406 <= __GNUC__ * 100 + __GNUC_MINOR__
+# if __GNUC__ * 100 + __GNUC_MINOR__ < 407
+# define YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN \
+ _Pragma ("GCC diagnostic push") \
+ _Pragma ("GCC diagnostic ignored \"-Wuninitialized\"")
+# else
+# define YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN \
_Pragma ("GCC diagnostic push") \
_Pragma ("GCC diagnostic ignored \"-Wuninitialized\"") \
_Pragma ("GCC diagnostic ignored \"-Wmaybe-uninitialized\"")
+# endif
# define YY_IGNORE_MAYBE_UNINITIALIZED_END \
_Pragma ("GCC diagnostic pop")
#else
#line 14 "dhcp4_parser.yy"
namespace isc { namespace dhcp {
-#line 204 "dhcp4_parser.h"
+#line 210 "dhcp4_parser.h"
class Dhcp4Parser
{
public:
-#ifndef PARSER4_STYPE
+#ifdef PARSER4_STYPE
+# ifdef __GNUC__
+# pragma GCC message "bison: do not #define PARSER4_STYPE in C++, use %define api.value.type"
+# endif
+ typedef PARSER4_STYPE value_type;
+#else
/// A buffer to store and retrieve objects.
///
/// Sort of a variant, but does not keep track of the nature
/// of the stored data, since that knowledge is available
/// via the current parser state.
- class semantic_type
+ class value_type
{
public:
/// Type of *this.
- typedef semantic_type self_type;
+ typedef value_type self_type;
/// Empty construction.
- semantic_type () YY_NOEXCEPT
- : yybuffer_ ()
+ value_type () YY_NOEXCEPT
+ : yyraw_ ()
, yytypeid_ (YY_NULLPTR)
{}
/// Construct and fill.
template <typename T>
- semantic_type (YY_RVREF (T) t)
+ value_type (YY_RVREF (T) t)
: yytypeid_ (&typeid (T))
{
PARSER4__ASSERT (sizeof (T) <= size);
#if 201103L <= YY_CPLUSPLUS
/// Non copyable.
- semantic_type (const self_type&) = delete;
+ value_type (const self_type&) = delete;
/// Non copyable.
self_type& operator= (const self_type&) = delete;
#endif
/// Destruction, allowed only if empty.
- ~semantic_type () YY_NOEXCEPT
+ ~value_type () YY_NOEXCEPT
{
PARSER4__ASSERT (!yytypeid_);
}
private:
#if YY_CPLUSPLUS < 201103L
/// Non copyable.
- semantic_type (const self_type&);
+ value_type (const self_type&);
/// Non copyable.
self_type& operator= (const self_type&);
#endif
T*
yyas_ () YY_NOEXCEPT
{
- void *yyp = yybuffer_.yyraw;
+ void *yyp = yyraw_;
return static_cast<T*> (yyp);
}
const T*
yyas_ () const YY_NOEXCEPT
{
- const void *yyp = yybuffer_.yyraw;
+ const void *yyp = yyraw_;
return static_cast<const T*> (yyp);
}
union
{
/// Strongest alignment constraints.
- long double yyalign_me;
+ long double yyalign_me_;
/// A buffer large enough to store any of the semantic values.
- char yyraw[size];
- } yybuffer_;
+ char yyraw_[size];
+ };
/// Whether the content is built: if defined, the name of the stored type.
const std::type_info *yytypeid_;
};
-#else
- typedef PARSER4_STYPE semantic_type;
#endif
+ /// Backward compatibility (Bison 3.8).
+ typedef value_type semantic_type;
+
/// Symbol locations.
typedef location location_type;
};
/// Token kind, as returned by yylex.
- typedef token::yytokentype token_kind_type;
+ typedef token::token_kind_type token_kind_type;
/// Backward compatibility alias (Bison 3.6).
typedef token_kind_type token_type;
typedef Base super_type;
/// Default constructor.
- basic_symbol ()
+ basic_symbol () YY_NOEXCEPT
: value ()
, location ()
{}
clear ();
}
+
+
/// Destroy contents, and record that is empty.
void clear () YY_NOEXCEPT
{
void move (basic_symbol& s);
/// The semantic value.
- semantic_type value;
+ value_type value;
/// The location.
location_type location;
/// Type access provider for token (enum) based symbols.
struct by_kind
{
+ /// The symbol kind as needed by the constructor.
+ typedef token_kind_type kind_type;
+
/// Default constructor.
- by_kind ();
+ by_kind () YY_NOEXCEPT;
#if 201103L <= YY_CPLUSPLUS
/// Move constructor.
- by_kind (by_kind&& that);
+ by_kind (by_kind&& that) YY_NOEXCEPT;
#endif
/// Copy constructor.
- by_kind (const by_kind& that);
-
- /// The symbol kind as needed by the constructor.
- typedef token_kind_type kind_type;
+ by_kind (const by_kind& that) YY_NOEXCEPT;
/// Constructor from (external) token numbers.
- by_kind (kind_type t);
+ by_kind (kind_type t) YY_NOEXCEPT;
+
+
/// Record that this symbol is empty.
void clear () YY_NOEXCEPT;
typedef basic_symbol<by_kind> super_type;
/// Empty symbol.
- symbol_type () {}
+ symbol_type () YY_NOEXCEPT {}
/// Constructor for valueless symbols, and symbols from each type.
#if 201103L <= YY_CPLUSPLUS
symbol_type (int tok, location_type l)
- : super_type(token_type (tok), std::move (l))
+ : super_type (token_kind_type (tok), std::move (l))
#else
symbol_type (int tok, const location_type& l)
- : super_type(token_type (tok), l)
+ : super_type (token_kind_type (tok), l)
#endif
{
+#if !defined _MSC_VER || defined __clang__
PARSER4__ASSERT (tok == token::TOKEN_END
|| (token::TOKEN_PARSER4_error <= tok && tok <= token::TOKEN_SUB_CONFIG_CONTROL));
+#endif
}
#if 201103L <= YY_CPLUSPLUS
symbol_type (int tok, bool v, location_type l)
- : super_type(token_type (tok), std::move (v), std::move (l))
+ : super_type (token_kind_type (tok), std::move (v), std::move (l))
#else
symbol_type (int tok, const bool& v, const location_type& l)
- : super_type(token_type (tok), v, l)
+ : super_type (token_kind_type (tok), v, l)
#endif
{
+#if !defined _MSC_VER || defined __clang__
PARSER4__ASSERT (tok == token::TOKEN_BOOLEAN);
+#endif
}
#if 201103L <= YY_CPLUSPLUS
symbol_type (int tok, double v, location_type l)
- : super_type(token_type (tok), std::move (v), std::move (l))
+ : super_type (token_kind_type (tok), std::move (v), std::move (l))
#else
symbol_type (int tok, const double& v, const location_type& l)
- : super_type(token_type (tok), v, l)
+ : super_type (token_kind_type (tok), v, l)
#endif
{
+#if !defined _MSC_VER || defined __clang__
PARSER4__ASSERT (tok == token::TOKEN_FLOAT);
+#endif
}
#if 201103L <= YY_CPLUSPLUS
symbol_type (int tok, int64_t v, location_type l)
- : super_type(token_type (tok), std::move (v), std::move (l))
+ : super_type (token_kind_type (tok), std::move (v), std::move (l))
#else
symbol_type (int tok, const int64_t& v, const location_type& l)
- : super_type(token_type (tok), v, l)
+ : super_type (token_kind_type (tok), v, l)
#endif
{
+#if !defined _MSC_VER || defined __clang__
PARSER4__ASSERT (tok == token::TOKEN_INTEGER);
+#endif
}
#if 201103L <= YY_CPLUSPLUS
symbol_type (int tok, std::string v, location_type l)
- : super_type(token_type (tok), std::move (v), std::move (l))
+ : super_type (token_kind_type (tok), std::move (v), std::move (l))
#else
symbol_type (int tok, const std::string& v, const location_type& l)
- : super_type(token_type (tok), v, l)
+ : super_type (token_kind_type (tok), v, l)
#endif
{
+#if !defined _MSC_VER || defined __clang__
PARSER4__ASSERT (tok == token::TOKEN_STRING);
+#endif
}
};
/// YYSYMBOL. No bounds checking.
static std::string symbol_name (symbol_kind_type yysymbol);
- // Implementation of make_symbol for each symbol type.
+ // Implementation of make_symbol for each token kind.
#if 201103L <= YY_CPLUSPLUS
static
symbol_type
/// Whether the given \c yypact_ value indicates a defaulted state.
/// \param yyvalue the value to check
- static bool yy_pact_value_is_default_ (int yyvalue);
+ static bool yy_pact_value_is_default_ (int yyvalue) YY_NOEXCEPT;
/// Whether the given \c yytable_ value indicates a syntax error.
/// \param yyvalue the value to check
- static bool yy_table_value_is_error_ (int yyvalue);
+ static bool yy_table_value_is_error_ (int yyvalue) YY_NOEXCEPT;
static const short yypact_ninf_;
static const signed char yytable_ninf_;
/// Convert a scanner token kind \a t to a symbol kind.
/// In theory \a t should be a token_kind_type, but character literals
- /// are valid, yet not members of the token_type enum.
- static symbol_kind_type yytranslate_ (int t);
+ /// are valid, yet not members of the token_kind_type enum.
+ static symbol_kind_type yytranslate_ (int t) YY_NOEXCEPT;
/// Convert the symbol name \a n to a form suitable for a diagnostic.
static std::string yytnamerr_ (const char *yystr);
static const short yycheck_[];
- // YYSTOS[STATE-NUM] -- The (internal number of the) accessing
- // symbol of state STATE-NUM.
+ // YYSTOS[STATE-NUM] -- The symbol kind of the accessing symbol of
+ // state STATE-NUM.
static const short yystos_[];
- // YYR1[YYN] -- Symbol number of symbol that rule YYN derives.
+ // YYR1[RULE-NUM] -- Symbol kind of the left-hand side of rule RULE-NUM.
static const short yyr1_[];
- // YYR2[YYN] -- Number of symbols on the right hand side of rule YYN.
+ // YYR2[RULE-NUM] -- Number of symbols on the right-hand side of rule RULE-NUM.
static const signed char yyr2_[];
typedef typename S::size_type size_type;
typedef typename std::ptrdiff_t index_type;
- stack (size_type n = 200)
+ stack (size_type n = 200) YY_NOEXCEPT
: seq_ (n)
{}
class slice
{
public:
- slice (const stack& stack, index_type range)
+ slice (const stack& stack, index_type range) YY_NOEXCEPT
: stack_ (stack)
, range_ (range)
{}
void yypush_ (const char* m, state_type s, YY_MOVE_REF (symbol_type) sym);
/// Pop \a n symbols from the stack.
- void yypop_ (int n = 1);
+ void yypop_ (int n = 1) YY_NOEXCEPT;
/// Constants.
enum
inline
Dhcp4Parser::symbol_kind_type
- Dhcp4Parser::yytranslate_ (int t)
+ Dhcp4Parser::yytranslate_ (int t) YY_NOEXCEPT
{
// YYTRANSLATE[TOKEN-NUM] -- Symbol number corresponding to
// TOKEN-NUM as returned by yylex.
if (t <= 0)
return symbol_kind::S_YYEOF;
else if (t <= code_max)
- return YY_CAST (symbol_kind_type, translate_table[t]);
+ return static_cast <symbol_kind_type> (translate_table[t]);
else
return symbol_kind::S_YYUNDEF;
}
+
template <typename Base>
Dhcp4Parser::symbol_kind_type
Dhcp4Parser::basic_symbol<Base>::type_get () const YY_NOEXCEPT
return this->kind ();
}
+
template <typename Base>
bool
Dhcp4Parser::basic_symbol<Base>::empty () const YY_NOEXCEPT
// by_kind.
inline
- Dhcp4Parser::by_kind::by_kind ()
+ Dhcp4Parser::by_kind::by_kind () YY_NOEXCEPT
: kind_ (symbol_kind::S_YYEMPTY)
{}
#if 201103L <= YY_CPLUSPLUS
inline
- Dhcp4Parser::by_kind::by_kind (by_kind&& that)
+ Dhcp4Parser::by_kind::by_kind (by_kind&& that) YY_NOEXCEPT
: kind_ (that.kind_)
{
that.clear ();
#endif
inline
- Dhcp4Parser::by_kind::by_kind (const by_kind& that)
+ Dhcp4Parser::by_kind::by_kind (const by_kind& that) YY_NOEXCEPT
: kind_ (that.kind_)
{}
inline
- Dhcp4Parser::by_kind::by_kind (token_kind_type t)
+ Dhcp4Parser::by_kind::by_kind (token_kind_type t) YY_NOEXCEPT
: kind_ (yytranslate_ (t))
{}
+
+
inline
void
Dhcp4Parser::by_kind::clear () YY_NOEXCEPT
return kind_;
}
+
inline
Dhcp4Parser::symbol_kind_type
Dhcp4Parser::by_kind::type_get () const YY_NOEXCEPT
return this->kind ();
}
+
#line 14 "dhcp4_parser.yy"
} } // isc::dhcp
-#line 5368 "dhcp4_parser.h"
+#line 5400 "dhcp4_parser.h"
-// A Bison parser, made by GNU Bison 3.7.6.
+// A Bison parser, made by GNU Bison 3.8.2.
// Locations for Bison parsers in C++
-// A Bison parser, made by GNU Bison 3.7.6.
+// A Bison parser, made by GNU Bison 3.8.2.
// Skeleton implementation for Bison LALR(1) parsers in C++
Dhcp6Parser::syntax_error::~syntax_error () YY_NOEXCEPT YY_NOTHROW
{}
- /*---------------.
- | symbol kinds. |
- `---------------*/
+ /*---------.
+ | symbol. |
+ `---------*/
}
void
- Dhcp6Parser::yypop_ (int n)
+ Dhcp6Parser::yypop_ (int n) YY_NOEXCEPT
{
yystack_.pop (n);
}
}
bool
- Dhcp6Parser::yy_pact_value_is_default_ (int yyvalue)
+ Dhcp6Parser::yy_pact_value_is_default_ (int yyvalue) YY_NOEXCEPT
{
return yyvalue == yypact_ninf_;
}
bool
- Dhcp6Parser::yy_table_value_is_error_ (int yyvalue)
+ Dhcp6Parser::yy_table_value_is_error_ (int yyvalue) YY_NOEXCEPT
{
return yyvalue == yytable_ninf_;
}
// Actual number of expected tokens
int yycount = 0;
- int yyn = yypact_[+yyparser_.yystack_[0].state];
+ const int yyn = yypact_[+yyparser_.yystack_[0].state];
if (!yy_pact_value_is_default_ (yyn))
{
/* Start YYX at -YYN if negative to avoid negative indexes in
YYCHECK. In other words, skip the first -YYN actions for
this state because they are default actions. */
- int yyxbegin = yyn < 0 ? -yyn : 0;
+ const int yyxbegin = yyn < 0 ? -yyn : 0;
// Stay within bounds of both yycheck and yytname.
- int yychecklim = yylast_ - yyn + 1;
- int yyxend = yychecklim < YYNTOKENS ? yychecklim : YYNTOKENS;
+ const int yychecklim = yylast_ - yyn + 1;
+ const int yyxend = yychecklim < YYNTOKENS ? yychecklim : YYNTOKENS;
for (int yyx = yyxbegin; yyx < yyxend; ++yyx)
if (yycheck_[yyx + yyn] == yyx && yyx != symbol_kind::S_YYerror
&& !yy_table_value_is_error_ (yytable_[yyx + yyn]))
+
+
+
int
Dhcp6Parser::yy_syntax_error_arguments_ (const context& yyctx,
symbol_kind_type yyarg[], int yyargn) const
#line 14 "dhcp6_parser.yy"
} } // isc::dhcp
-#line 5981 "dhcp6_parser.cc"
+#line 5984 "dhcp6_parser.cc"
#line 2864 "dhcp6_parser.yy"
-// A Bison parser, made by GNU Bison 3.7.6.
+// A Bison parser, made by GNU Bison 3.8.2.
// Skeleton interface for Bison LALR(1) parsers in C++
# define YY_USE(E) /* empty */
#endif
-#if defined __GNUC__ && ! defined __ICC && 407 <= __GNUC__ * 100 + __GNUC_MINOR__
/* Suppress an incorrect diagnostic about yylval being uninitialized. */
-# define YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN \
+#if defined __GNUC__ && ! defined __ICC && 406 <= __GNUC__ * 100 + __GNUC_MINOR__
+# if __GNUC__ * 100 + __GNUC_MINOR__ < 407
+# define YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN \
+ _Pragma ("GCC diagnostic push") \
+ _Pragma ("GCC diagnostic ignored \"-Wuninitialized\"")
+# else
+# define YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN \
_Pragma ("GCC diagnostic push") \
_Pragma ("GCC diagnostic ignored \"-Wuninitialized\"") \
_Pragma ("GCC diagnostic ignored \"-Wmaybe-uninitialized\"")
+# endif
# define YY_IGNORE_MAYBE_UNINITIALIZED_END \
_Pragma ("GCC diagnostic pop")
#else
#line 14 "dhcp6_parser.yy"
namespace isc { namespace dhcp {
-#line 204 "dhcp6_parser.h"
+#line 210 "dhcp6_parser.h"
class Dhcp6Parser
{
public:
-#ifndef PARSER6_STYPE
+#ifdef PARSER6_STYPE
+# ifdef __GNUC__
+# pragma GCC message "bison: do not #define PARSER6_STYPE in C++, use %define api.value.type"
+# endif
+ typedef PARSER6_STYPE value_type;
+#else
/// A buffer to store and retrieve objects.
///
/// Sort of a variant, but does not keep track of the nature
/// of the stored data, since that knowledge is available
/// via the current parser state.
- class semantic_type
+ class value_type
{
public:
/// Type of *this.
- typedef semantic_type self_type;
+ typedef value_type self_type;
/// Empty construction.
- semantic_type () YY_NOEXCEPT
- : yybuffer_ ()
+ value_type () YY_NOEXCEPT
+ : yyraw_ ()
, yytypeid_ (YY_NULLPTR)
{}
/// Construct and fill.
template <typename T>
- semantic_type (YY_RVREF (T) t)
+ value_type (YY_RVREF (T) t)
: yytypeid_ (&typeid (T))
{
PARSER6__ASSERT (sizeof (T) <= size);
#if 201103L <= YY_CPLUSPLUS
/// Non copyable.
- semantic_type (const self_type&) = delete;
+ value_type (const self_type&) = delete;
/// Non copyable.
self_type& operator= (const self_type&) = delete;
#endif
/// Destruction, allowed only if empty.
- ~semantic_type () YY_NOEXCEPT
+ ~value_type () YY_NOEXCEPT
{
PARSER6__ASSERT (!yytypeid_);
}
private:
#if YY_CPLUSPLUS < 201103L
/// Non copyable.
- semantic_type (const self_type&);
+ value_type (const self_type&);
/// Non copyable.
self_type& operator= (const self_type&);
#endif
T*
yyas_ () YY_NOEXCEPT
{
- void *yyp = yybuffer_.yyraw;
+ void *yyp = yyraw_;
return static_cast<T*> (yyp);
}
const T*
yyas_ () const YY_NOEXCEPT
{
- const void *yyp = yybuffer_.yyraw;
+ const void *yyp = yyraw_;
return static_cast<const T*> (yyp);
}
union
{
/// Strongest alignment constraints.
- long double yyalign_me;
+ long double yyalign_me_;
/// A buffer large enough to store any of the semantic values.
- char yyraw[size];
- } yybuffer_;
+ char yyraw_[size];
+ };
/// Whether the content is built: if defined, the name of the stored type.
const std::type_info *yytypeid_;
};
-#else
- typedef PARSER6_STYPE semantic_type;
#endif
+ /// Backward compatibility (Bison 3.8).
+ typedef value_type semantic_type;
+
/// Symbol locations.
typedef location location_type;
};
/// Token kind, as returned by yylex.
- typedef token::yytokentype token_kind_type;
+ typedef token::token_kind_type token_kind_type;
/// Backward compatibility alias (Bison 3.6).
typedef token_kind_type token_type;
typedef Base super_type;
/// Default constructor.
- basic_symbol ()
+ basic_symbol () YY_NOEXCEPT
: value ()
, location ()
{}
clear ();
}
+
+
/// Destroy contents, and record that is empty.
void clear () YY_NOEXCEPT
{
void move (basic_symbol& s);
/// The semantic value.
- semantic_type value;
+ value_type value;
/// The location.
location_type location;
/// Type access provider for token (enum) based symbols.
struct by_kind
{
+ /// The symbol kind as needed by the constructor.
+ typedef token_kind_type kind_type;
+
/// Default constructor.
- by_kind ();
+ by_kind () YY_NOEXCEPT;
#if 201103L <= YY_CPLUSPLUS
/// Move constructor.
- by_kind (by_kind&& that);
+ by_kind (by_kind&& that) YY_NOEXCEPT;
#endif
/// Copy constructor.
- by_kind (const by_kind& that);
-
- /// The symbol kind as needed by the constructor.
- typedef token_kind_type kind_type;
+ by_kind (const by_kind& that) YY_NOEXCEPT;
/// Constructor from (external) token numbers.
- by_kind (kind_type t);
+ by_kind (kind_type t) YY_NOEXCEPT;
+
+
/// Record that this symbol is empty.
void clear () YY_NOEXCEPT;
typedef basic_symbol<by_kind> super_type;
/// Empty symbol.
- symbol_type () {}
+ symbol_type () YY_NOEXCEPT {}
/// Constructor for valueless symbols, and symbols from each type.
#if 201103L <= YY_CPLUSPLUS
symbol_type (int tok, location_type l)
- : super_type(token_type (tok), std::move (l))
+ : super_type (token_kind_type (tok), std::move (l))
#else
symbol_type (int tok, const location_type& l)
- : super_type(token_type (tok), l)
+ : super_type (token_kind_type (tok), l)
#endif
{
+#if !defined _MSC_VER || defined __clang__
PARSER6__ASSERT (tok == token::TOKEN_END
|| (token::TOKEN_PARSER6_error <= tok && tok <= token::TOKEN_SUB_CONFIG_CONTROL));
+#endif
}
#if 201103L <= YY_CPLUSPLUS
symbol_type (int tok, bool v, location_type l)
- : super_type(token_type (tok), std::move (v), std::move (l))
+ : super_type (token_kind_type (tok), std::move (v), std::move (l))
#else
symbol_type (int tok, const bool& v, const location_type& l)
- : super_type(token_type (tok), v, l)
+ : super_type (token_kind_type (tok), v, l)
#endif
{
+#if !defined _MSC_VER || defined __clang__
PARSER6__ASSERT (tok == token::TOKEN_BOOLEAN);
+#endif
}
#if 201103L <= YY_CPLUSPLUS
symbol_type (int tok, double v, location_type l)
- : super_type(token_type (tok), std::move (v), std::move (l))
+ : super_type (token_kind_type (tok), std::move (v), std::move (l))
#else
symbol_type (int tok, const double& v, const location_type& l)
- : super_type(token_type (tok), v, l)
+ : super_type (token_kind_type (tok), v, l)
#endif
{
+#if !defined _MSC_VER || defined __clang__
PARSER6__ASSERT (tok == token::TOKEN_FLOAT);
+#endif
}
#if 201103L <= YY_CPLUSPLUS
symbol_type (int tok, int64_t v, location_type l)
- : super_type(token_type (tok), std::move (v), std::move (l))
+ : super_type (token_kind_type (tok), std::move (v), std::move (l))
#else
symbol_type (int tok, const int64_t& v, const location_type& l)
- : super_type(token_type (tok), v, l)
+ : super_type (token_kind_type (tok), v, l)
#endif
{
+#if !defined _MSC_VER || defined __clang__
PARSER6__ASSERT (tok == token::TOKEN_INTEGER);
+#endif
}
#if 201103L <= YY_CPLUSPLUS
symbol_type (int tok, std::string v, location_type l)
- : super_type(token_type (tok), std::move (v), std::move (l))
+ : super_type (token_kind_type (tok), std::move (v), std::move (l))
#else
symbol_type (int tok, const std::string& v, const location_type& l)
- : super_type(token_type (tok), v, l)
+ : super_type (token_kind_type (tok), v, l)
#endif
{
+#if !defined _MSC_VER || defined __clang__
PARSER6__ASSERT (tok == token::TOKEN_STRING);
+#endif
}
};
/// YYSYMBOL. No bounds checking.
static std::string symbol_name (symbol_kind_type yysymbol);
- // Implementation of make_symbol for each symbol type.
+ // Implementation of make_symbol for each token kind.
#if 201103L <= YY_CPLUSPLUS
static
symbol_type
/// Whether the given \c yypact_ value indicates a defaulted state.
/// \param yyvalue the value to check
- static bool yy_pact_value_is_default_ (int yyvalue);
+ static bool yy_pact_value_is_default_ (int yyvalue) YY_NOEXCEPT;
/// Whether the given \c yytable_ value indicates a syntax error.
/// \param yyvalue the value to check
- static bool yy_table_value_is_error_ (int yyvalue);
+ static bool yy_table_value_is_error_ (int yyvalue) YY_NOEXCEPT;
static const short yypact_ninf_;
static const signed char yytable_ninf_;
/// Convert a scanner token kind \a t to a symbol kind.
/// In theory \a t should be a token_kind_type, but character literals
- /// are valid, yet not members of the token_type enum.
- static symbol_kind_type yytranslate_ (int t);
+ /// are valid, yet not members of the token_kind_type enum.
+ static symbol_kind_type yytranslate_ (int t) YY_NOEXCEPT;
/// Convert the symbol name \a n to a form suitable for a diagnostic.
static std::string yytnamerr_ (const char *yystr);
static const short yycheck_[];
- // YYSTOS[STATE-NUM] -- The (internal number of the) accessing
- // symbol of state STATE-NUM.
+ // YYSTOS[STATE-NUM] -- The symbol kind of the accessing symbol of
+ // state STATE-NUM.
static const short yystos_[];
- // YYR1[YYN] -- Symbol number of symbol that rule YYN derives.
+ // YYR1[RULE-NUM] -- Symbol kind of the left-hand side of rule RULE-NUM.
static const short yyr1_[];
- // YYR2[YYN] -- Number of symbols on the right hand side of rule YYN.
+ // YYR2[RULE-NUM] -- Number of symbols on the right-hand side of rule RULE-NUM.
static const signed char yyr2_[];
typedef typename S::size_type size_type;
typedef typename std::ptrdiff_t index_type;
- stack (size_type n = 200)
+ stack (size_type n = 200) YY_NOEXCEPT
: seq_ (n)
{}
class slice
{
public:
- slice (const stack& stack, index_type range)
+ slice (const stack& stack, index_type range) YY_NOEXCEPT
: stack_ (stack)
, range_ (range)
{}
void yypush_ (const char* m, state_type s, YY_MOVE_REF (symbol_type) sym);
/// Pop \a n symbols from the stack.
- void yypop_ (int n = 1);
+ void yypop_ (int n = 1) YY_NOEXCEPT;
/// Constants.
enum
inline
Dhcp6Parser::symbol_kind_type
- Dhcp6Parser::yytranslate_ (int t)
+ Dhcp6Parser::yytranslate_ (int t) YY_NOEXCEPT
{
// YYTRANSLATE[TOKEN-NUM] -- Symbol number corresponding to
// TOKEN-NUM as returned by yylex.
if (t <= 0)
return symbol_kind::S_YYEOF;
else if (t <= code_max)
- return YY_CAST (symbol_kind_type, translate_table[t]);
+ return static_cast <symbol_kind_type> (translate_table[t]);
else
return symbol_kind::S_YYUNDEF;
}
+
template <typename Base>
Dhcp6Parser::symbol_kind_type
Dhcp6Parser::basic_symbol<Base>::type_get () const YY_NOEXCEPT
return this->kind ();
}
+
template <typename Base>
bool
Dhcp6Parser::basic_symbol<Base>::empty () const YY_NOEXCEPT
// by_kind.
inline
- Dhcp6Parser::by_kind::by_kind ()
+ Dhcp6Parser::by_kind::by_kind () YY_NOEXCEPT
: kind_ (symbol_kind::S_YYEMPTY)
{}
#if 201103L <= YY_CPLUSPLUS
inline
- Dhcp6Parser::by_kind::by_kind (by_kind&& that)
+ Dhcp6Parser::by_kind::by_kind (by_kind&& that) YY_NOEXCEPT
: kind_ (that.kind_)
{
that.clear ();
#endif
inline
- Dhcp6Parser::by_kind::by_kind (const by_kind& that)
+ Dhcp6Parser::by_kind::by_kind (const by_kind& that) YY_NOEXCEPT
: kind_ (that.kind_)
{}
inline
- Dhcp6Parser::by_kind::by_kind (token_kind_type t)
+ Dhcp6Parser::by_kind::by_kind (token_kind_type t) YY_NOEXCEPT
: kind_ (yytranslate_ (t))
{}
+
+
inline
void
Dhcp6Parser::by_kind::clear () YY_NOEXCEPT
return kind_;
}
+
inline
Dhcp6Parser::symbol_kind_type
Dhcp6Parser::by_kind::type_get () const YY_NOEXCEPT
return this->kind ();
}
+
#line 14 "dhcp6_parser.yy"
} } // isc::dhcp
-#line 5520 "dhcp6_parser.h"
+#line 5552 "dhcp6_parser.h"
-// A Bison parser, made by GNU Bison 3.7.6.
+// A Bison parser, made by GNU Bison 3.8.2.
// Locations for Bison parsers in C++
-// A Bison parser, made by GNU Bison 3.7.6.
+// A Bison parser, made by GNU Bison 3.8.2.
// Locations for Bison parsers in C++
-// A Bison parser, made by GNU Bison 3.7.6.
+// A Bison parser, made by GNU Bison 3.8.2.
// Skeleton implementation for Bison LALR(1) parsers in C++
NetconfParser::syntax_error::~syntax_error () YY_NOEXCEPT YY_NOTHROW
{}
- /*---------------.
- | symbol kinds. |
- `---------------*/
+ /*---------.
+ | symbol. |
+ `---------*/
}
void
- NetconfParser::yypop_ (int n)
+ NetconfParser::yypop_ (int n) YY_NOEXCEPT
{
yystack_.pop (n);
}
}
bool
- NetconfParser::yy_pact_value_is_default_ (int yyvalue)
+ NetconfParser::yy_pact_value_is_default_ (int yyvalue) YY_NOEXCEPT
{
return yyvalue == yypact_ninf_;
}
bool
- NetconfParser::yy_table_value_is_error_ (int yyvalue)
+ NetconfParser::yy_table_value_is_error_ (int yyvalue) YY_NOEXCEPT
{
return yyvalue == yytable_ninf_;
}
// Actual number of expected tokens
int yycount = 0;
- int yyn = yypact_[+yyparser_.yystack_[0].state];
+ const int yyn = yypact_[+yyparser_.yystack_[0].state];
if (!yy_pact_value_is_default_ (yyn))
{
/* Start YYX at -YYN if negative to avoid negative indexes in
YYCHECK. In other words, skip the first -YYN actions for
this state because they are default actions. */
- int yyxbegin = yyn < 0 ? -yyn : 0;
+ const int yyxbegin = yyn < 0 ? -yyn : 0;
// Stay within bounds of both yycheck and yytname.
- int yychecklim = yylast_ - yyn + 1;
- int yyxend = yychecklim < YYNTOKENS ? yychecklim : YYNTOKENS;
+ const int yychecklim = yylast_ - yyn + 1;
+ const int yyxend = yychecklim < YYNTOKENS ? yychecklim : YYNTOKENS;
for (int yyx = yyxbegin; yyx < yyxend; ++yyx)
if (yycheck_[yyx + yyn] == yyx && yyx != symbol_kind::S_YYerror
&& !yy_table_value_is_error_ (yytable_[yyx + yyn]))
+
+
+
int
NetconfParser::yy_syntax_error_arguments_ (const context& yyctx,
symbol_kind_type yyarg[], int yyargn) const
#line 14 "netconf_parser.yy"
} } // isc::netconf
-#line 2192 "netconf_parser.cc"
+#line 2195 "netconf_parser.cc"
#line 706 "netconf_parser.yy"
-// A Bison parser, made by GNU Bison 3.7.6.
+// A Bison parser, made by GNU Bison 3.8.2.
// Skeleton interface for Bison LALR(1) parsers in C++
# define YY_USE(E) /* empty */
#endif
-#if defined __GNUC__ && ! defined __ICC && 407 <= __GNUC__ * 100 + __GNUC_MINOR__
/* Suppress an incorrect diagnostic about yylval being uninitialized. */
-# define YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN \
+#if defined __GNUC__ && ! defined __ICC && 406 <= __GNUC__ * 100 + __GNUC_MINOR__
+# if __GNUC__ * 100 + __GNUC_MINOR__ < 407
+# define YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN \
+ _Pragma ("GCC diagnostic push") \
+ _Pragma ("GCC diagnostic ignored \"-Wuninitialized\"")
+# else
+# define YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN \
_Pragma ("GCC diagnostic push") \
_Pragma ("GCC diagnostic ignored \"-Wuninitialized\"") \
_Pragma ("GCC diagnostic ignored \"-Wmaybe-uninitialized\"")
+# endif
# define YY_IGNORE_MAYBE_UNINITIALIZED_END \
_Pragma ("GCC diagnostic pop")
#else
#line 14 "netconf_parser.yy"
namespace isc { namespace netconf {
-#line 203 "netconf_parser.h"
+#line 209 "netconf_parser.h"
class NetconfParser
{
public:
-#ifndef NETCONF_STYPE
+#ifdef NETCONF_STYPE
+# ifdef __GNUC__
+# pragma GCC message "bison: do not #define NETCONF_STYPE in C++, use %define api.value.type"
+# endif
+ typedef NETCONF_STYPE value_type;
+#else
/// A buffer to store and retrieve objects.
///
/// Sort of a variant, but does not keep track of the nature
/// of the stored data, since that knowledge is available
/// via the current parser state.
- class semantic_type
+ class value_type
{
public:
/// Type of *this.
- typedef semantic_type self_type;
+ typedef value_type self_type;
/// Empty construction.
- semantic_type () YY_NOEXCEPT
- : yybuffer_ ()
+ value_type () YY_NOEXCEPT
+ : yyraw_ ()
, yytypeid_ (YY_NULLPTR)
{}
/// Construct and fill.
template <typename T>
- semantic_type (YY_RVREF (T) t)
+ value_type (YY_RVREF (T) t)
: yytypeid_ (&typeid (T))
{
NETCONF__ASSERT (sizeof (T) <= size);
#if 201103L <= YY_CPLUSPLUS
/// Non copyable.
- semantic_type (const self_type&) = delete;
+ value_type (const self_type&) = delete;
/// Non copyable.
self_type& operator= (const self_type&) = delete;
#endif
/// Destruction, allowed only if empty.
- ~semantic_type () YY_NOEXCEPT
+ ~value_type () YY_NOEXCEPT
{
NETCONF__ASSERT (!yytypeid_);
}
private:
#if YY_CPLUSPLUS < 201103L
/// Non copyable.
- semantic_type (const self_type&);
+ value_type (const self_type&);
/// Non copyable.
self_type& operator= (const self_type&);
#endif
T*
yyas_ () YY_NOEXCEPT
{
- void *yyp = yybuffer_.yyraw;
+ void *yyp = yyraw_;
return static_cast<T*> (yyp);
}
const T*
yyas_ () const YY_NOEXCEPT
{
- const void *yyp = yybuffer_.yyraw;
+ const void *yyp = yyraw_;
return static_cast<const T*> (yyp);
}
union
{
/// Strongest alignment constraints.
- long double yyalign_me;
+ long double yyalign_me_;
/// A buffer large enough to store any of the semantic values.
- char yyraw[size];
- } yybuffer_;
+ char yyraw_[size];
+ };
/// Whether the content is built: if defined, the name of the stored type.
const std::type_info *yytypeid_;
};
-#else
- typedef NETCONF_STYPE semantic_type;
#endif
+ /// Backward compatibility (Bison 3.8).
+ typedef value_type semantic_type;
+
/// Symbol locations.
typedef location location_type;
};
/// Token kind, as returned by yylex.
- typedef token::yytokentype token_kind_type;
+ typedef token::token_kind_type token_kind_type;
/// Backward compatibility alias (Bison 3.6).
typedef token_kind_type token_type;
typedef Base super_type;
/// Default constructor.
- basic_symbol ()
+ basic_symbol () YY_NOEXCEPT
: value ()
, location ()
{}
clear ();
}
+
+
/// Destroy contents, and record that is empty.
void clear () YY_NOEXCEPT
{
void move (basic_symbol& s);
/// The semantic value.
- semantic_type value;
+ value_type value;
/// The location.
location_type location;
/// Type access provider for token (enum) based symbols.
struct by_kind
{
+ /// The symbol kind as needed by the constructor.
+ typedef token_kind_type kind_type;
+
/// Default constructor.
- by_kind ();
+ by_kind () YY_NOEXCEPT;
#if 201103L <= YY_CPLUSPLUS
/// Move constructor.
- by_kind (by_kind&& that);
+ by_kind (by_kind&& that) YY_NOEXCEPT;
#endif
/// Copy constructor.
- by_kind (const by_kind& that);
-
- /// The symbol kind as needed by the constructor.
- typedef token_kind_type kind_type;
+ by_kind (const by_kind& that) YY_NOEXCEPT;
/// Constructor from (external) token numbers.
- by_kind (kind_type t);
+ by_kind (kind_type t) YY_NOEXCEPT;
+
+
/// Record that this symbol is empty.
void clear () YY_NOEXCEPT;
typedef basic_symbol<by_kind> super_type;
/// Empty symbol.
- symbol_type () {}
+ symbol_type () YY_NOEXCEPT {}
/// Constructor for valueless symbols, and symbols from each type.
#if 201103L <= YY_CPLUSPLUS
symbol_type (int tok, location_type l)
- : super_type(token_type (tok), std::move (l))
+ : super_type (token_kind_type (tok), std::move (l))
#else
symbol_type (int tok, const location_type& l)
- : super_type(token_type (tok), l)
+ : super_type (token_kind_type (tok), l)
#endif
{
+#if !defined _MSC_VER || defined __clang__
NETCONF__ASSERT (tok == token::TOKEN_END
|| (token::TOKEN_NETCONF_error <= tok && tok <= token::TOKEN_START_SUB_NETCONF));
+#endif
}
#if 201103L <= YY_CPLUSPLUS
symbol_type (int tok, bool v, location_type l)
- : super_type(token_type (tok), std::move (v), std::move (l))
+ : super_type (token_kind_type (tok), std::move (v), std::move (l))
#else
symbol_type (int tok, const bool& v, const location_type& l)
- : super_type(token_type (tok), v, l)
+ : super_type (token_kind_type (tok), v, l)
#endif
{
+#if !defined _MSC_VER || defined __clang__
NETCONF__ASSERT (tok == token::TOKEN_BOOLEAN);
+#endif
}
#if 201103L <= YY_CPLUSPLUS
symbol_type (int tok, double v, location_type l)
- : super_type(token_type (tok), std::move (v), std::move (l))
+ : super_type (token_kind_type (tok), std::move (v), std::move (l))
#else
symbol_type (int tok, const double& v, const location_type& l)
- : super_type(token_type (tok), v, l)
+ : super_type (token_kind_type (tok), v, l)
#endif
{
+#if !defined _MSC_VER || defined __clang__
NETCONF__ASSERT (tok == token::TOKEN_FLOAT);
+#endif
}
#if 201103L <= YY_CPLUSPLUS
symbol_type (int tok, int64_t v, location_type l)
- : super_type(token_type (tok), std::move (v), std::move (l))
+ : super_type (token_kind_type (tok), std::move (v), std::move (l))
#else
symbol_type (int tok, const int64_t& v, const location_type& l)
- : super_type(token_type (tok), v, l)
+ : super_type (token_kind_type (tok), v, l)
#endif
{
+#if !defined _MSC_VER || defined __clang__
NETCONF__ASSERT (tok == token::TOKEN_INTEGER);
+#endif
}
#if 201103L <= YY_CPLUSPLUS
symbol_type (int tok, std::string v, location_type l)
- : super_type(token_type (tok), std::move (v), std::move (l))
+ : super_type (token_kind_type (tok), std::move (v), std::move (l))
#else
symbol_type (int tok, const std::string& v, const location_type& l)
- : super_type(token_type (tok), v, l)
+ : super_type (token_kind_type (tok), v, l)
#endif
{
+#if !defined _MSC_VER || defined __clang__
NETCONF__ASSERT (tok == token::TOKEN_STRING);
+#endif
}
};
/// YYSYMBOL. No bounds checking.
static std::string symbol_name (symbol_kind_type yysymbol);
- // Implementation of make_symbol for each symbol type.
+ // Implementation of make_symbol for each token kind.
#if 201103L <= YY_CPLUSPLUS
static
symbol_type
/// Whether the given \c yypact_ value indicates a defaulted state.
/// \param yyvalue the value to check
- static bool yy_pact_value_is_default_ (int yyvalue);
+ static bool yy_pact_value_is_default_ (int yyvalue) YY_NOEXCEPT;
/// Whether the given \c yytable_ value indicates a syntax error.
/// \param yyvalue the value to check
- static bool yy_table_value_is_error_ (int yyvalue);
+ static bool yy_table_value_is_error_ (int yyvalue) YY_NOEXCEPT;
static const signed char yypact_ninf_;
static const signed char yytable_ninf_;
/// Convert a scanner token kind \a t to a symbol kind.
/// In theory \a t should be a token_kind_type, but character literals
- /// are valid, yet not members of the token_type enum.
- static symbol_kind_type yytranslate_ (int t);
+ /// are valid, yet not members of the token_kind_type enum.
+ static symbol_kind_type yytranslate_ (int t) YY_NOEXCEPT;
/// Convert the symbol name \a n to a form suitable for a diagnostic.
static std::string yytnamerr_ (const char *yystr);
static const short yycheck_[];
- // YYSTOS[STATE-NUM] -- The (internal number of the) accessing
- // symbol of state STATE-NUM.
+ // YYSTOS[STATE-NUM] -- The symbol kind of the accessing symbol of
+ // state STATE-NUM.
static const unsigned char yystos_[];
- // YYR1[YYN] -- Symbol number of symbol that rule YYN derives.
+ // YYR1[RULE-NUM] -- Symbol kind of the left-hand side of rule RULE-NUM.
static const unsigned char yyr1_[];
- // YYR2[YYN] -- Number of symbols on the right hand side of rule YYN.
+ // YYR2[RULE-NUM] -- Number of symbols on the right-hand side of rule RULE-NUM.
static const signed char yyr2_[];
typedef typename S::size_type size_type;
typedef typename std::ptrdiff_t index_type;
- stack (size_type n = 200)
+ stack (size_type n = 200) YY_NOEXCEPT
: seq_ (n)
{}
class slice
{
public:
- slice (const stack& stack, index_type range)
+ slice (const stack& stack, index_type range) YY_NOEXCEPT
: stack_ (stack)
, range_ (range)
{}
void yypush_ (const char* m, state_type s, YY_MOVE_REF (symbol_type) sym);
/// Pop \a n symbols from the stack.
- void yypop_ (int n = 1);
+ void yypop_ (int n = 1) YY_NOEXCEPT;
/// Constants.
enum
inline
NetconfParser::symbol_kind_type
- NetconfParser::yytranslate_ (int t)
+ NetconfParser::yytranslate_ (int t) YY_NOEXCEPT
{
// YYTRANSLATE[TOKEN-NUM] -- Symbol number corresponding to
// TOKEN-NUM as returned by yylex.
if (t <= 0)
return symbol_kind::S_YYEOF;
else if (t <= code_max)
- return YY_CAST (symbol_kind_type, translate_table[t]);
+ return static_cast <symbol_kind_type> (translate_table[t]);
else
return symbol_kind::S_YYUNDEF;
}
+
template <typename Base>
NetconfParser::symbol_kind_type
NetconfParser::basic_symbol<Base>::type_get () const YY_NOEXCEPT
return this->kind ();
}
+
template <typename Base>
bool
NetconfParser::basic_symbol<Base>::empty () const YY_NOEXCEPT
// by_kind.
inline
- NetconfParser::by_kind::by_kind ()
+ NetconfParser::by_kind::by_kind () YY_NOEXCEPT
: kind_ (symbol_kind::S_YYEMPTY)
{}
#if 201103L <= YY_CPLUSPLUS
inline
- NetconfParser::by_kind::by_kind (by_kind&& that)
+ NetconfParser::by_kind::by_kind (by_kind&& that) YY_NOEXCEPT
: kind_ (that.kind_)
{
that.clear ();
#endif
inline
- NetconfParser::by_kind::by_kind (const by_kind& that)
+ NetconfParser::by_kind::by_kind (const by_kind& that) YY_NOEXCEPT
: kind_ (that.kind_)
{}
inline
- NetconfParser::by_kind::by_kind (token_kind_type t)
+ NetconfParser::by_kind::by_kind (token_kind_type t) YY_NOEXCEPT
: kind_ (yytranslate_ (t))
{}
+
+
inline
void
NetconfParser::by_kind::clear () YY_NOEXCEPT
return kind_;
}
+
inline
NetconfParser::symbol_kind_type
NetconfParser::by_kind::type_get () const YY_NOEXCEPT
return this->kind ();
}
+
#line 14 "netconf_parser.yy"
} } // isc::netconf
-#line 2350 "netconf_parser.h"
+#line 2382 "netconf_parser.h"
-// A Bison parser, made by GNU Bison 3.7.6.
+// A Bison parser, made by GNU Bison 3.8.2.
// Locations for Bison parsers in C++
-// A Bison parser, made by GNU Bison 3.7.6.
+// A Bison parser, made by GNU Bison 3.8.2.
// Skeleton implementation for Bison LALR(1) parsers in C++
EvalParser::syntax_error::~syntax_error () YY_NOEXCEPT YY_NOTHROW
{}
- /*---------------.
- | symbol kinds. |
- `---------------*/
+ /*---------.
+ | symbol. |
+ `---------*/
}
void
- EvalParser::yypop_ (int n)
+ EvalParser::yypop_ (int n) YY_NOEXCEPT
{
yystack_.pop (n);
}
}
bool
- EvalParser::yy_pact_value_is_default_ (int yyvalue)
+ EvalParser::yy_pact_value_is_default_ (int yyvalue) YY_NOEXCEPT
{
return yyvalue == yypact_ninf_;
}
bool
- EvalParser::yy_table_value_is_error_ (int yyvalue)
+ EvalParser::yy_table_value_is_error_ (int yyvalue) YY_NOEXCEPT
{
return yyvalue == yytable_ninf_;
}
// Actual number of expected tokens
int yycount = 0;
- int yyn = yypact_[+yyparser_.yystack_[0].state];
+ const int yyn = yypact_[+yyparser_.yystack_[0].state];
if (!yy_pact_value_is_default_ (yyn))
{
/* Start YYX at -YYN if negative to avoid negative indexes in
YYCHECK. In other words, skip the first -YYN actions for
this state because they are default actions. */
- int yyxbegin = yyn < 0 ? -yyn : 0;
+ const int yyxbegin = yyn < 0 ? -yyn : 0;
// Stay within bounds of both yycheck and yytname.
- int yychecklim = yylast_ - yyn + 1;
- int yyxend = yychecklim < YYNTOKENS ? yychecklim : YYNTOKENS;
+ const int yychecklim = yylast_ - yyn + 1;
+ const int yyxend = yychecklim < YYNTOKENS ? yychecklim : YYNTOKENS;
for (int yyx = yyxbegin; yyx < yyxend; ++yyx)
if (yycheck_[yyx + yyn] == yyx && yyx != symbol_kind::S_YYerror
&& !yy_table_value_is_error_ (yytable_[yyx + yyn]))
+
+
+
int
EvalParser::yy_syntax_error_arguments_ (const context& yyctx,
symbol_kind_type yyarg[], int yyargn) const
#line 14 "parser.yy"
} } // isc::eval
-#line 2188 "parser.cc"
+#line 2191 "parser.cc"
#line 626 "parser.yy"
-// A Bison parser, made by GNU Bison 3.7.6.
+// A Bison parser, made by GNU Bison 3.8.2.
// Skeleton interface for Bison LALR(1) parsers in C++
# define YY_USE(E) /* empty */
#endif
-#if defined __GNUC__ && ! defined __ICC && 407 <= __GNUC__ * 100 + __GNUC_MINOR__
/* Suppress an incorrect diagnostic about yylval being uninitialized. */
-# define YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN \
+#if defined __GNUC__ && ! defined __ICC && 406 <= __GNUC__ * 100 + __GNUC_MINOR__
+# if __GNUC__ * 100 + __GNUC_MINOR__ < 407
+# define YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN \
+ _Pragma ("GCC diagnostic push") \
+ _Pragma ("GCC diagnostic ignored \"-Wuninitialized\"")
+# else
+# define YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN \
_Pragma ("GCC diagnostic push") \
_Pragma ("GCC diagnostic ignored \"-Wuninitialized\"") \
_Pragma ("GCC diagnostic ignored \"-Wmaybe-uninitialized\"")
+# endif
# define YY_IGNORE_MAYBE_UNINITIALIZED_END \
_Pragma ("GCC diagnostic pop")
#else
#line 14 "parser.yy"
namespace isc { namespace eval {
-#line 203 "parser.h"
+#line 209 "parser.h"
class EvalParser
{
public:
-#ifndef EVALSTYPE
+#ifdef EVALSTYPE
+# ifdef __GNUC__
+# pragma GCC message "bison: do not #define EVALSTYPE in C++, use %define api.value.type"
+# endif
+ typedef EVALSTYPE value_type;
+#else
/// A buffer to store and retrieve objects.
///
/// Sort of a variant, but does not keep track of the nature
/// of the stored data, since that knowledge is available
/// via the current parser state.
- class semantic_type
+ class value_type
{
public:
/// Type of *this.
- typedef semantic_type self_type;
+ typedef value_type self_type;
/// Empty construction.
- semantic_type () YY_NOEXCEPT
- : yybuffer_ ()
+ value_type () YY_NOEXCEPT
+ : yyraw_ ()
, yytypeid_ (YY_NULLPTR)
{}
/// Construct and fill.
template <typename T>
- semantic_type (YY_RVREF (T) t)
+ value_type (YY_RVREF (T) t)
: yytypeid_ (&typeid (T))
{
EVAL_ASSERT (sizeof (T) <= size);
#if 201103L <= YY_CPLUSPLUS
/// Non copyable.
- semantic_type (const self_type&) = delete;
+ value_type (const self_type&) = delete;
/// Non copyable.
self_type& operator= (const self_type&) = delete;
#endif
/// Destruction, allowed only if empty.
- ~semantic_type () YY_NOEXCEPT
+ ~value_type () YY_NOEXCEPT
{
EVAL_ASSERT (!yytypeid_);
}
private:
#if YY_CPLUSPLUS < 201103L
/// Non copyable.
- semantic_type (const self_type&);
+ value_type (const self_type&);
/// Non copyable.
self_type& operator= (const self_type&);
#endif
T*
yyas_ () YY_NOEXCEPT
{
- void *yyp = yybuffer_.yyraw;
+ void *yyp = yyraw_;
return static_cast<T*> (yyp);
}
const T*
yyas_ () const YY_NOEXCEPT
{
- const void *yyp = yybuffer_.yyraw;
+ const void *yyp = yyraw_;
return static_cast<const T*> (yyp);
}
union
{
/// Strongest alignment constraints.
- long double yyalign_me;
+ long double yyalign_me_;
/// A buffer large enough to store any of the semantic values.
- char yyraw[size];
- } yybuffer_;
+ char yyraw_[size];
+ };
/// Whether the content is built: if defined, the name of the stored type.
const std::type_info *yytypeid_;
};
-#else
- typedef EVALSTYPE semantic_type;
#endif
+ /// Backward compatibility (Bison 3.8).
+ typedef value_type semantic_type;
+
/// Symbol locations.
typedef location location_type;
};
/// Token kind, as returned by yylex.
- typedef token::yytokentype token_kind_type;
+ typedef token::token_kind_type token_kind_type;
/// Backward compatibility alias (Bison 3.6).
typedef token_kind_type token_type;
typedef Base super_type;
/// Default constructor.
- basic_symbol ()
+ basic_symbol () YY_NOEXCEPT
: value ()
, location ()
{}
clear ();
}
+
+
/// Destroy contents, and record that is empty.
void clear () YY_NOEXCEPT
{
void move (basic_symbol& s);
/// The semantic value.
- semantic_type value;
+ value_type value;
/// The location.
location_type location;
/// Type access provider for token (enum) based symbols.
struct by_kind
{
+ /// The symbol kind as needed by the constructor.
+ typedef token_kind_type kind_type;
+
/// Default constructor.
- by_kind ();
+ by_kind () YY_NOEXCEPT;
#if 201103L <= YY_CPLUSPLUS
/// Move constructor.
- by_kind (by_kind&& that);
+ by_kind (by_kind&& that) YY_NOEXCEPT;
#endif
/// Copy constructor.
- by_kind (const by_kind& that);
-
- /// The symbol kind as needed by the constructor.
- typedef token_kind_type kind_type;
+ by_kind (const by_kind& that) YY_NOEXCEPT;
/// Constructor from (external) token numbers.
- by_kind (kind_type t);
+ by_kind (kind_type t) YY_NOEXCEPT;
+
+
/// Record that this symbol is empty.
void clear () YY_NOEXCEPT;
typedef basic_symbol<by_kind> super_type;
/// Empty symbol.
- symbol_type () {}
+ symbol_type () YY_NOEXCEPT {}
/// Constructor for valueless symbols, and symbols from each type.
#if 201103L <= YY_CPLUSPLUS
symbol_type (int tok, location_type l)
- : super_type(token_type (tok), std::move (l))
+ : super_type (token_kind_type (tok), std::move (l))
#else
symbol_type (int tok, const location_type& l)
- : super_type(token_type (tok), l)
+ : super_type (token_kind_type (tok), l)
#endif
{
+#if !defined _MSC_VER || defined __clang__
EVAL_ASSERT (tok == token::TOKEN_END
|| (token::TOKEN_EVALerror <= tok && tok <= token::TOKEN_TOPLEVEL_STRING));
+#endif
}
#if 201103L <= YY_CPLUSPLUS
symbol_type (int tok, std::string v, location_type l)
- : super_type(token_type (tok), std::move (v), std::move (l))
+ : super_type (token_kind_type (tok), std::move (v), std::move (l))
#else
symbol_type (int tok, const std::string& v, const location_type& l)
- : super_type(token_type (tok), v, l)
+ : super_type (token_kind_type (tok), v, l)
#endif
{
+#if !defined _MSC_VER || defined __clang__
EVAL_ASSERT ((token::TOKEN_STRING <= tok && tok <= token::TOKEN_IP_ADDRESS));
+#endif
}
};
/// YYSYMBOL. No bounds checking.
static std::string symbol_name (symbol_kind_type yysymbol);
- // Implementation of make_symbol for each symbol type.
+ // Implementation of make_symbol for each token kind.
#if 201103L <= YY_CPLUSPLUS
static
symbol_type
/// Whether the given \c yypact_ value indicates a defaulted state.
/// \param yyvalue the value to check
- static bool yy_pact_value_is_default_ (int yyvalue);
+ static bool yy_pact_value_is_default_ (int yyvalue) YY_NOEXCEPT;
/// Whether the given \c yytable_ value indicates a syntax error.
/// \param yyvalue the value to check
- static bool yy_table_value_is_error_ (int yyvalue);
+ static bool yy_table_value_is_error_ (int yyvalue) YY_NOEXCEPT;
static const short yypact_ninf_;
static const signed char yytable_ninf_;
/// Convert a scanner token kind \a t to a symbol kind.
/// In theory \a t should be a token_kind_type, but character literals
- /// are valid, yet not members of the token_type enum.
- static symbol_kind_type yytranslate_ (int t);
+ /// are valid, yet not members of the token_kind_type enum.
+ static symbol_kind_type yytranslate_ (int t) YY_NOEXCEPT;
/// Convert the symbol name \a n to a form suitable for a diagnostic.
static std::string yytnamerr_ (const char *yystr);
static const unsigned char yycheck_[];
- // YYSTOS[STATE-NUM] -- The (internal number of the) accessing
- // symbol of state STATE-NUM.
+ // YYSTOS[STATE-NUM] -- The symbol kind of the accessing symbol of
+ // state STATE-NUM.
static const signed char yystos_[];
- // YYR1[YYN] -- Symbol number of symbol that rule YYN derives.
+ // YYR1[RULE-NUM] -- Symbol kind of the left-hand side of rule RULE-NUM.
static const signed char yyr1_[];
- // YYR2[YYN] -- Number of symbols on the right hand side of rule YYN.
+ // YYR2[RULE-NUM] -- Number of symbols on the right-hand side of rule RULE-NUM.
static const signed char yyr2_[];
typedef typename S::size_type size_type;
typedef typename std::ptrdiff_t index_type;
- stack (size_type n = 200)
+ stack (size_type n = 200) YY_NOEXCEPT
: seq_ (n)
{}
class slice
{
public:
- slice (const stack& stack, index_type range)
+ slice (const stack& stack, index_type range) YY_NOEXCEPT
: stack_ (stack)
, range_ (range)
{}
void yypush_ (const char* m, state_type s, YY_MOVE_REF (symbol_type) sym);
/// Pop \a n symbols from the stack.
- void yypop_ (int n = 1);
+ void yypop_ (int n = 1) YY_NOEXCEPT;
/// Constants.
enum
inline
EvalParser::symbol_kind_type
- EvalParser::yytranslate_ (int t)
+ EvalParser::yytranslate_ (int t) YY_NOEXCEPT
{
// YYTRANSLATE[TOKEN-NUM] -- Symbol number corresponding to
// TOKEN-NUM as returned by yylex.
if (t <= 0)
return symbol_kind::S_YYEOF;
else if (t <= code_max)
- return YY_CAST (symbol_kind_type, translate_table[t]);
+ return static_cast <symbol_kind_type> (translate_table[t]);
else
return symbol_kind::S_YYUNDEF;
}
+
template <typename Base>
EvalParser::symbol_kind_type
EvalParser::basic_symbol<Base>::type_get () const YY_NOEXCEPT
return this->kind ();
}
+
template <typename Base>
bool
EvalParser::basic_symbol<Base>::empty () const YY_NOEXCEPT
// by_kind.
inline
- EvalParser::by_kind::by_kind ()
+ EvalParser::by_kind::by_kind () YY_NOEXCEPT
: kind_ (symbol_kind::S_YYEMPTY)
{}
#if 201103L <= YY_CPLUSPLUS
inline
- EvalParser::by_kind::by_kind (by_kind&& that)
+ EvalParser::by_kind::by_kind (by_kind&& that) YY_NOEXCEPT
: kind_ (that.kind_)
{
that.clear ();
#endif
inline
- EvalParser::by_kind::by_kind (const by_kind& that)
+ EvalParser::by_kind::by_kind (const by_kind& that) YY_NOEXCEPT
: kind_ (that.kind_)
{}
inline
- EvalParser::by_kind::by_kind (token_kind_type t)
+ EvalParser::by_kind::by_kind (token_kind_type t) YY_NOEXCEPT
: kind_ (yytranslate_ (t))
{}
+
+
inline
void
EvalParser::by_kind::clear () YY_NOEXCEPT
return kind_;
}
+
inline
EvalParser::symbol_kind_type
EvalParser::by_kind::type_get () const YY_NOEXCEPT
return this->kind ();
}
+
#line 14 "parser.yy"
} } // isc::eval
-#line 2629 "parser.h"
+#line 2655 "parser.h"