![]() |
Kea
1.5.0
|
A Bison parser. More...
#include <parser.h>
Classes | |
| struct | basic_symbol |
| A complete symbol. More... | |
| struct | by_type |
| Type access provider for token (enum) based symbols. More... | |
| struct | syntax_error |
| Syntax errors thrown from user actions. More... | |
| struct | token |
| Tokens. More... | |
| union | union_type |
| An auxiliary type to compute the largest semantic type. More... | |
Public Types | |
| enum | { empty_symbol = -2 } |
| The symbol type number to denote an empty symbol. More... | |
| typedef int | debug_level_type |
| Type for debugging levels. More... | |
| typedef location | location_type |
| Symbol locations. More... | |
| typedef variant< sizeof(union_type)> | semantic_type |
| Symbol semantic values. More... | |
| typedef int | symbol_number_type |
| Symbol type: an internal symbol number. More... | |
| typedef basic_symbol< by_type > | symbol_type |
| "External" symbols: returned by the scanner. More... | |
| typedef unsigned char | token_number_type |
| Internal symbol number for tokens (subsumed by symbol_number_type). More... | |
| typedef token::yytokentype | token_type |
| (External) token type, as returned by yylex. More... | |
Public Member Functions | |
| EvalParser (EvalContext &ctx_yyarg) | |
| Build a parser object. More... | |
| virtual | ~EvalParser () |
| debug_level_type | debug_level () const YY_ATTRIBUTE_PURE |
| The current debugging level. More... | |
| std::ostream & | debug_stream () const YY_ATTRIBUTE_PURE |
| The current debugging stream. More... | |
| virtual void | error (const location_type &loc, const std::string &msg) |
| Report a syntax error. More... | |
| void | error (const syntax_error &err) |
| Report a syntax error. More... | |
| int | operator() () |
| Parse. More... | |
| virtual int | parse () |
| Parse. More... | |
| void | set_debug_level (debug_level_type l) |
| Set the current debugging level. More... | |
| void | set_debug_stream (std::ostream &) |
| Set the current debugging stream. More... | |
| typedef int isc::eval::EvalParser::debug_level_type |
| typedef location isc::eval::EvalParser::location_type |
| typedef variant<sizeof (union_type)> isc::eval::EvalParser::semantic_type |
| typedef int isc::eval::EvalParser::symbol_number_type |
| typedef unsigned char isc::eval::EvalParser::token_number_type |
| anonymous enum |
| isc::eval::EvalParser::EvalParser | ( | EvalContext & | ctx_yyarg | ) |
| EvalParser::debug_level_type isc::eval::EvalParser::debug_level | ( | ) | const |
| std::ostream & isc::eval::EvalParser::debug_stream | ( | ) | const |
|
virtual |
Report a syntax error.
| loc | where the syntax error is found. |
| msg | a description of the syntax error. |
Definition at line 1933 of file parser.cc.
References isc::eval::EvalContext::error().
Referenced by error(), and parse().
Here is the call graph for this function:| void isc::eval::EvalParser::error | ( | const syntax_error & | err | ) |
Report a syntax error.
Definition at line 1593 of file parser.cc.
References error(), and isc::eval::EvalParser::syntax_error::location.
Here is the call graph for this function:
|
inlinestatic |
Definition at line 1895 of file parser.h.
References isc::eval::EvalParser::token::TOKEN_ALL, and YY_MOVE.
|
inlinestatic |
Definition at line 1692 of file parser.h.
References isc::eval::EvalParser::token::TOKEN_AND, and YY_MOVE.
|
inlinestatic |
Definition at line 1965 of file parser.h.
References isc::eval::EvalParser::token::TOKEN_ANY, and YY_MOVE.
|
inlinestatic |
Definition at line 1839 of file parser.h.
References isc::eval::EvalParser::token::TOKEN_CHADDR, and YY_MOVE.
|
inlinestatic |
Definition at line 1860 of file parser.h.
References isc::eval::EvalParser::token::TOKEN_CIADDR, and YY_MOVE.
|
inlinestatic |
Definition at line 1902 of file parser.h.
References isc::eval::EvalParser::token::TOKEN_COMA, and YY_MOVE.
|
inlinestatic |
Definition at line 1909 of file parser.h.
References isc::eval::EvalParser::token::TOKEN_CONCAT, and YY_MOVE.
|
inlinestatic |
Definition at line 1972 of file parser.h.
References isc::eval::EvalParser::token::TOKEN_DATA, and YY_MOVE.
|
inlinestatic |
Definition at line 1769 of file parser.h.
References isc::eval::EvalParser::token::TOKEN_DOT, and YY_MOVE.
|
inlinestatic |
Definition at line 1818 of file parser.h.
References isc::eval::EvalParser::token::TOKEN_DST, and YY_MOVE.
|
inlinestatic |
Definition at line 1664 of file parser.h.
References isc::eval::EvalParser::token::TOKEN_END, and YY_MOVE.
|
inlinestatic |
Definition at line 1979 of file parser.h.
References isc::eval::EvalParser::token::TOKEN_ENTERPRISE, and YY_MOVE.
|
inlinestatic |
Definition at line 1706 of file parser.h.
References isc::eval::EvalParser::token::TOKEN_EQUAL, and YY_MOVE.
|
inlinestatic |
Definition at line 1790 of file parser.h.
References isc::eval::EvalParser::token::TOKEN_EXISTS, and YY_MOVE.
|
inlinestatic |
Definition at line 1867 of file parser.h.
References isc::eval::EvalParser::token::TOKEN_GIADDR, and YY_MOVE.
|
inlinestatic |
Definition at line 1783 of file parser.h.
References isc::eval::EvalParser::token::TOKEN_HEX, and YY_MOVE.
|
inlinestatic |
Definition at line 2014 of file parser.h.
References isc::eval::EvalParser::token::TOKEN_HEXSTRING, and YY_MOVE.
|
inlinestatic |
Definition at line 1846 of file parser.h.
References isc::eval::EvalParser::token::TOKEN_HLEN, and YY_MOVE.
|
inlinestatic |
Definition at line 1853 of file parser.h.
References isc::eval::EvalParser::token::TOKEN_HTYPE, and YY_MOVE.
|
inlinestatic |
Definition at line 1804 of file parser.h.
References isc::eval::EvalParser::token::TOKEN_IFACE, and YY_MOVE.
|
inlinestatic |
Definition at line 1916 of file parser.h.
References isc::eval::EvalParser::token::TOKEN_IFELSE, and YY_MOVE.
|
inlinestatic |
Definition at line 2007 of file parser.h.
References isc::eval::EvalParser::token::TOKEN_INTEGER, and YY_MOVE.
|
inlinestatic |
Definition at line 2028 of file parser.h.
References isc::eval::EvalParser::token::TOKEN_IP_ADDRESS, and YY_MOVE.
|
inlinestatic |
Definition at line 1755 of file parser.h.
References isc::eval::EvalParser::token::TOKEN_LBRACKET, and YY_MOVE.
|
inlinestatic |
Definition at line 1825 of file parser.h.
References isc::eval::EvalParser::token::TOKEN_LEN, and YY_MOVE.
|
inlinestatic |
Definition at line 1748 of file parser.h.
References isc::eval::EvalParser::token::TOKEN_LINKADDR, and YY_MOVE.
|
inlinestatic |
Definition at line 1671 of file parser.h.
References isc::eval::EvalParser::token::TOKEN_LPAREN, and YY_MOVE.
|
inlinestatic |
Definition at line 1734 of file parser.h.
References isc::eval::EvalParser::token::TOKEN_MEMBER, and YY_MOVE.
|
inlinestatic |
Definition at line 1937 of file parser.h.
References isc::eval::EvalParser::token::TOKEN_MSGTYPE, and YY_MOVE.
|
inlinestatic |
Definition at line 1685 of file parser.h.
References isc::eval::EvalParser::token::TOKEN_NOT, and YY_MOVE.
|
inlinestatic |
Definition at line 1713 of file parser.h.
References isc::eval::EvalParser::token::TOKEN_OPTION, and YY_MOVE.
|
inlinestatic |
Definition at line 2021 of file parser.h.
References isc::eval::EvalParser::token::TOKEN_OPTION_NAME, and YY_MOVE.
|
inlinestatic |
Definition at line 1699 of file parser.h.
References isc::eval::EvalParser::token::TOKEN_OR, and YY_MOVE.
|
inlinestatic |
Definition at line 1741 of file parser.h.
References isc::eval::EvalParser::token::TOKEN_PEERADDR, and YY_MOVE.
|
inlinestatic |
Definition at line 1797 of file parser.h.
References isc::eval::EvalParser::token::TOKEN_PKT, and YY_MOVE.
|
inlinestatic |
Definition at line 1832 of file parser.h.
References isc::eval::EvalParser::token::TOKEN_PKT4, and YY_MOVE.
|
inlinestatic |
Definition at line 1930 of file parser.h.
References isc::eval::EvalParser::token::TOKEN_PKT6, and YY_MOVE.
|
inlinestatic |
Definition at line 1762 of file parser.h.
References isc::eval::EvalParser::token::TOKEN_RBRACKET, and YY_MOVE.
|
inlinestatic |
Definition at line 1720 of file parser.h.
References isc::eval::EvalParser::token::TOKEN_RELAY4, and YY_MOVE.
|
inlinestatic |
Definition at line 1727 of file parser.h.
References isc::eval::EvalParser::token::TOKEN_RELAY6, and YY_MOVE.
|
inlinestatic |
Definition at line 1678 of file parser.h.
References isc::eval::EvalParser::token::TOKEN_RPAREN, and YY_MOVE.
|
inlinestatic |
Definition at line 1881 of file parser.h.
References isc::eval::EvalParser::token::TOKEN_SIADDR, and YY_MOVE.
|
inlinestatic |
Definition at line 1811 of file parser.h.
References isc::eval::EvalParser::token::TOKEN_SRC, and YY_MOVE.
|
inlinestatic |
Definition at line 2000 of file parser.h.
References isc::eval::EvalParser::token::TOKEN_STRING, and YY_MOVE.
|
inlinestatic |
Definition at line 1888 of file parser.h.
References isc::eval::EvalParser::token::TOKEN_SUBSTRING, and YY_MOVE.
|
inlinestatic |
Definition at line 1776 of file parser.h.
References isc::eval::EvalParser::token::TOKEN_TEXT, and YY_MOVE.
|
inlinestatic |
Definition at line 1923 of file parser.h.
References isc::eval::EvalParser::token::TOKEN_TOHEXSTRING, and YY_MOVE.
|
inlinestatic |
Definition at line 1986 of file parser.h.
References isc::eval::EvalParser::token::TOKEN_TOPLEVEL_BOOL, and YY_MOVE.
|
inlinestatic |
Definition at line 1993 of file parser.h.
References isc::eval::EvalParser::token::TOKEN_TOPLEVEL_STRING, and YY_MOVE.
|
inlinestatic |
Definition at line 1944 of file parser.h.
References isc::eval::EvalParser::token::TOKEN_TRANSID, and YY_MOVE.
|
inlinestatic |
Definition at line 1958 of file parser.h.
References isc::eval::EvalParser::token::TOKEN_VENDOR, and YY_MOVE.
|
inlinestatic |
Definition at line 1951 of file parser.h.
References isc::eval::EvalParser::token::TOKEN_VENDOR_CLASS, and YY_MOVE.
|
inlinestatic |
Definition at line 1874 of file parser.h.
References isc::eval::EvalParser::token::TOKEN_YIADDR, and YY_MOVE.
| int isc::eval::EvalParser::operator() | ( | ) |
|
virtual |
Parse.
Length of the RHS of the rule being reduced.
The lookahead symbol.
The locations where the error started and ended.
The return value of parse ().
Definition at line 625 of file parser.cc.
References isc::eval::stack< T, S >::clear(), isc::eval::EvalParser::basic_symbol< Base >::clear(), isc::eval::EvalContext::convertNestLevelNumber(), isc::eval::EvalContext::convertOptionCode(), isc::eval::EvalContext::convertOptionName(), isc::eval::EvalContext::convertUint32(), isc::eval::EvalContext::convertUint8(), isc::eval::EvalParser::basic_symbol< Base >::empty(), error(), isc::eval::EvalContext::expression, isc::eval::EvalContext::getUniverse(), isc::eval::EvalContext::isClientClassDefined(), isc::eval::EvalParser::basic_symbol< Base >::location, isc::eval::EvalParser::basic_symbol< Base >::move(), isc::eval::stack< T, S >::size(), YY_MOVE, YY_REDUCE_PRINT, YY_STACK_PRINT, YY_SYMBOL_PRINT, YYABORT, YYCDEBUG, YYERROR, yylex, and YYLLOC_DEFAULT.
Referenced by operator()(), and isc::eval::EvalContext::parseString().
Here is the call graph for this function:| void isc::eval::EvalParser::set_debug_level | ( | debug_level_type | l | ) |
Set the current debugging level.
Definition at line 590 of file parser.cc.
Referenced by isc::eval::EvalContext::parseString().
| void isc::eval::EvalParser::set_debug_stream | ( | std::ostream & | o | ) |