|
| InstantiationSyntax (InstantiationBuilder &, InstantiationSemantic &) |
|
virtual void | configure (Config &) |
| Configure the syntactic analysis object.
|
|
InstantiationTokenSource & | source () const |
|
InstantiationTokenProvider & | provider () const |
|
virtual bool | class_name () |
|
virtual bool | enum_name () |
|
virtual bool | template_name () |
|
virtual bool | class_template_name () |
|
virtual bool | namespace_name () |
|
virtual bool | typedef_name () |
|
virtual bool | template_id () |
|
virtual bool | class_template_id () |
|
bool | type_param_without_init () |
|
CTree * | rule_type_param_without_init () |
|
bool | non_type_param_without_init () |
|
CTree * | rule_non_type_param_without_init () |
|
| CCSyntax (CCBuilder &, CCSemantic &) |
|
virtual Grammar | grammar () const |
|
void | config_skip_fct_body (bool s) |
|
virtual bool | original_ns_name () |
|
virtual bool | namespace_alias () |
|
virtual bool | literal () |
|
virtual bool | prim_expr () |
|
virtual bool | id_expr () |
|
virtual bool | qual_id () |
|
virtual bool | unqual_id () |
|
virtual bool | colon_colon () |
|
virtual bool | nested_name_spec () |
|
virtual bool | nested_name_spec1 () |
|
virtual bool | class_or_ns_name () |
|
virtual bool | postfix_expr () |
|
virtual bool | postfix_expr1 () |
|
virtual bool | postfix_expr2 () |
|
virtual bool | construct_expr () |
|
virtual bool | pseudo_dtor_name () |
|
virtual bool | unary_expr () |
|
virtual bool | type_trait_expr () |
|
virtual bool | new_expr () |
|
virtual bool | new_placement () |
|
virtual bool | new_type_id () |
|
virtual bool | new_declarator () |
|
virtual bool | direct_new_declarator () |
|
virtual bool | direct_new_declarator1 () |
|
virtual bool | new_init () |
|
virtual bool | delete_expr () |
|
virtual bool | pm_expr () |
|
virtual bool | mul_expr () |
|
virtual bool | rel_expr () |
|
virtual bool | cond_expr () |
|
virtual bool | ass_expr () |
|
virtual bool | ass_expr1 () |
|
virtual bool | const_expr () |
|
virtual bool | stmt () |
|
virtual bool | stmt_seq () |
|
virtual bool | sub_stmt () |
|
virtual bool | condition () |
|
virtual bool | condition1 () |
|
virtual bool | condition2 () |
|
virtual bool | decl_stmt () |
|
virtual bool | decl () |
|
virtual bool | decl_check () |
|
virtual bool | block_decl () |
|
virtual bool | simple_decl () |
|
virtual bool | decl_spec_seq1 () |
|
virtual bool | misc_spec () |
|
virtual bool | storage_class_spec () |
|
virtual bool | fct_spec () |
|
virtual bool | simple_type_spec () |
|
virtual bool | type_name () |
|
virtual bool | elaborated_type_spec () |
|
virtual bool | enumerator_list () |
|
virtual bool | enumerator_def () |
|
virtual bool | linkage_spec () |
|
virtual bool | namespace_def () |
|
virtual bool | named_ns_def () |
|
virtual bool | original_ns_def () |
|
virtual bool | original_ns_def1 () |
|
virtual bool | extension_ns_def () |
|
virtual bool | extension_ns_def1 () |
|
virtual bool | unnamed_ns_def () |
|
virtual bool | unnamed_ns_def1 () |
|
virtual bool | namespace_body () |
|
virtual bool | ns_alias_def () |
|
virtual bool | qual_ns_spec () |
|
virtual bool | using_decl () |
|
virtual bool | using_directive () |
|
virtual bool | init_declarator () |
|
virtual bool | direct_declarator1 () |
|
virtual bool | array_delim () |
|
virtual bool | ptr_operator () |
|
virtual bool | declarator_id () |
|
virtual bool | direct_abst_declarator () |
|
virtual bool | param_decl_clause () |
|
CTree * | rule_param_decl () |
|
virtual bool | param_decl () |
|
CTree * | rule_param_init () |
|
virtual bool | param_init () |
|
CTree * | rule_fct_def () |
|
virtual bool | fct_def () |
|
CTree * | rule_skipped_fct_body () |
|
virtual bool | skipped_fct_body () |
|
CTree * | rule_fct_body () |
|
virtual bool | fct_body () |
|
CTree * | rule_init () |
|
virtual bool | init () |
|
CTree * | rule_init_clause () |
|
virtual bool | init_clause () |
|
CTree * | rule_class_spec () |
|
virtual bool | class_spec () |
|
virtual bool | class_head () |
|
virtual bool | class_head1 () |
|
CTree * | rule_member_decl () |
|
virtual bool | member_decl () |
|
CTree * | rule_member_decl1 () |
|
virtual bool | member_decl1 () |
|
CTree * | rule_access_decl () |
|
virtual bool | access_decl () |
|
CTree * | rule_member_declarator () |
|
virtual bool | member_declarator () |
|
CTree * | rule_pure_spec () |
|
virtual bool | pure_spec () |
|
CTree * | rule_const_init () |
|
virtual bool | const_init () |
|
CTree * | rule_base_clause () |
|
virtual bool | base_clause () |
|
CTree * | rule_base_spec_list () |
|
virtual bool | base_spec_list () |
|
CTree * | rule_base_spec () |
|
virtual bool | base_spec () |
|
CTree * | rule_access_spec () |
|
virtual bool | access_spec () |
|
virtual bool | conv_fct_id () |
|
virtual bool | conv_type_id () |
|
CTree * | rule_conv_declarator () |
|
virtual bool | conv_declarator () |
|
CTree * | rule_ctor_init () |
|
virtual bool | ctor_init () |
|
CTree * | rule_mem_init_list () |
|
virtual bool | mem_init_list () |
|
CTree * | rule_mem_init () |
|
virtual bool | mem_init () |
|
CTree * | rule_mem_init_id () |
|
virtual bool | mem_init_id () |
|
CTree * | rule_oper_fct_id () |
|
virtual bool | oper_fct_id () |
|
CTree * | rule_template_key () |
|
virtual bool | template_key () |
|
CTree * | rule_template_decl () |
|
virtual bool | template_decl () |
|
CTree * | rule_member_template_decl () |
|
virtual bool | member_template_decl () |
|
CTree * | rule_template_param_list () |
|
virtual bool | template_param_list () |
|
CTree * | rule_template_param () |
|
virtual bool | template_param () |
|
CTree * | rule_type_param () |
|
virtual bool | type_param () |
|
CTree * | rule_non_type_param () |
|
virtual bool | non_type_param () |
|
CTree * | rule_template_id () |
|
CTree * | rule_class_template_id () |
|
CTree * | rule_template_arg_list () |
|
virtual bool | template_arg_list () |
|
CTree * | rule_template_arg () |
|
virtual bool | template_arg () |
|
CTree * | rule_template_type_arg () |
|
virtual bool | template_type_arg () |
|
CTree * | rule_template_non_type_arg () |
|
virtual bool | template_non_type_arg () |
|
CTree * | rule_template_template_arg () |
|
virtual bool | template_template_arg () |
|
CTree * | rule_explicit_instantiation () |
|
virtual bool | explicit_instantiation () |
|
CTree * | rule_explicit_specialization () |
|
virtual bool | explicit_specialization () |
|
CTree * | rule_try_block () |
|
virtual bool | try_block () |
|
CTree * | rule_fct_try_block () |
|
virtual bool | fct_try_block () |
|
CTree * | rule_handler_seq () |
|
virtual bool | handler_seq () |
|
CTree * | rule_handler () |
|
virtual bool | handler () |
|
CTree * | rule_exception_decl () |
|
virtual bool | exception_decl () |
|
CTree * | rule_throw_expr () |
|
virtual bool | throw_expr () |
|
CTree * | rule_exception_spec () |
|
virtual bool | exception_spec () |
|
CTree * | rule_type_id_list () |
|
virtual bool | type_id_list () |
|
| CSyntax (CBuilder &, CSemantic &) |
|
virtual bool | private_name () |
|
virtual bool | identifier () |
|
virtual bool | cmpd_str () |
|
virtual bool | str_literal () |
|
virtual bool | trans_unit () |
| Top parse rule to be reimplemented for a specific grammar.
|
|
virtual bool | cmpd_literal () |
|
virtual bool | expr_list () |
|
virtual bool | unary_expr1 () |
|
virtual bool | cast_expr () |
|
virtual bool | cast_expr1 () |
|
virtual bool | cast_expr2 () |
|
virtual bool | offsetof_expr () |
|
virtual bool | memb_designator () |
|
virtual bool | add_expr () |
|
virtual bool | shift_expr () |
|
virtual bool | equ_expr () |
|
virtual bool | and_expr () |
|
virtual bool | excl_or_expr () |
|
virtual bool | incl_or_expr () |
|
virtual bool | log_and_expr () |
|
virtual bool | log_or_expr () |
|
virtual bool | expr () |
|
virtual bool | label_stmt () |
|
virtual bool | expr_stmt () |
|
virtual bool | cmpd_stmt () |
|
virtual bool | select_stmt () |
|
virtual bool | iter_stmt () |
|
virtual bool | for_init_stmt () |
|
virtual bool | jump_stmt () |
|
virtual bool | decl_seq () |
|
virtual bool | decl_spec () |
|
virtual bool | decl_spec_seq () |
|
virtual bool | type_spec () |
|
virtual bool | enum_key () |
|
virtual bool | enum_spec () |
|
virtual bool | enum_spec1 () |
|
virtual bool | enumerator () |
|
virtual bool | asm_def () |
|
virtual bool | init_declarator_list () |
|
virtual bool | init_declarator1 () |
|
virtual bool | declarator () |
|
virtual bool | direct_declarator () |
|
virtual bool | identifier_list () |
|
virtual bool | cv_qual_seq () |
|
virtual bool | cv_qual () |
|
virtual bool | type_id () |
|
virtual bool | type_spec_seq () |
|
virtual bool | type_spec_seq1 () |
|
virtual bool | abst_declarator () |
|
virtual bool | direct_abst_declarator1 () |
|
virtual bool | param_decl_list () |
|
CTree * | rule_param_decl () |
|
virtual bool | param_decl1 () |
|
CTree * | rule_fct_def () |
|
CTree * | rule_arg_decl_seq () |
|
virtual bool | arg_decl_seq () |
|
CTree * | rule_fct_body () |
|
CTree * | rule_init () |
|
CTree * | rule_init_clause () |
|
CTree * | rule_init_list () |
|
virtual bool | init_list () |
|
CTree * | rule_init_list_item () |
|
virtual bool | init_list_item () |
|
CTree * | rule_designation () |
|
virtual bool | designation () |
|
CTree * | rule_designator () |
|
virtual bool | designator () |
|
CTree * | rule_class_spec () |
|
virtual bool | class_key () |
|
CTree * | rule_member_spec () |
|
virtual bool | member_spec () |
|
CTree * | rule_member_decl () |
|
CTree * | rule_member_declarator_list () |
|
virtual bool | member_declarator_list () |
|
CTree * | rule_member_declarator () |
|
pointcut | parse_fct () |
| Interface for aspects that affect the syntax and parsing process.
|
|
pointcut | check_fct () |
|
pointcut | in_syntax () |
|
pointcut | rule_exec () |
|
pointcut | rule_call () |
|
pointcut | rule_check () |
|
CTree * | run (TokenProvider &tp) |
| Start the parse process.
|
|
template<class T > |
CTree * | run (TokenProvider &tp, bool(T::*rule)()) |
| Start the parse process at a specific grammar rule.
|
|
TokenProvider * | provider () const |
| Get the token provider from which the parsed tokens are read.
|
|
Token * | problem () const |
| Get the last token that could not be parsed.
|
|
bool | error () const |
| Check if errors occured during the parse process.
|
|
bool | look_ahead (int token_type, unsigned n=1) |
| Look-ahead n core language tokens and check if the n-th token has the given type.
|
|
bool | look_ahead (int *token_types, unsigned n=1) |
| Look-ahead n core language tokens and check if the n-th token has one of the given types.
|
|
int | look_ahead (unsigned n=1) |
| Look-ahead one core language token.
|
|
bool | consume () |
| Consume all tokens until the next core language token.
|
|
bool | predict_1 (const tokenset &ts) |
|
template<class T > |
bool | parse (CTree *(T::*rule)()) |
| Parse the given grammar rule.
|
|
template<class T > |
bool | seq (CTree *(T::*rule)()) |
| Parse a sequence of the given grammar rule.
|
|
template<class T > |
bool | seq (bool(T::*rule)()) |
| Parse a sequence of the given grammar rule.
|
|
template<class T > |
bool | list (CTree *(T::*rule)(), int separator, bool trailing_separator=false) |
| Parse a sequence of rule-separator pairs.
|
|
template<class T > |
bool | list (CTree *(T::*rule)(), int *separators, bool trailing_separator=false) |
| Parse a sequence of rule-separator pairs.
|
|
template<class T > |
bool | list (bool(T::*rule)(), int separator, bool trailing_separator=false) |
| Parse a sequence of rule-separator pairs.
|
|
template<class T > |
bool | list (bool(T::*rule)(), int *separators, bool trailing_separator=false) |
| Parse a sequence of rule-separator pairs.
|
|
template<class T > |
bool | catch_error (bool(T::*rule)(), const char *msg, int *finish_tokens, int *skip_tokens) |
| Parse a grammar rule automatically catching parse errors.
|
|
bool | parse (int token_type) |
| Parse a token with the given type.
|
|
bool | parse (int *token_types) |
| Parse a token with one of the given types.
|
|
bool | parse_token (int token_type) |
| Parse a token with the given type.
|
|
bool | opt (bool dummy) const |
| Optional rule parsing.
|
|
Builder & | builder () const |
| Get the syntax tree builder.
|
|
Semantic & | semantic () const |
| Get the semantic analysis object.
|
|
State | save_state () |
| Save the current parser state.
|
|
void | forget_state () |
| Forget the saved parser state.
|
|
void | restore_state () |
| Restore the saved parser state.
|
|
void | restore_state (State state) |
| Restore the saved parser state to the given state.
|
|
void | set_state (State state) |
| Overwrite the parser state with the given state.
|
|
bool | accept (CTree *tree, State state) |
| Accept the given syntax tree node.
|
|
CTree * | accept (CTree *tree) |
| Accept the given syntax tree node.
|
|
Token * | locate_token () |
| Skip all non-core language tokens until the next core-language token is read.
|
|
void | skip () |
| Skip the current token.
|
|
void | skip_block (int start, int end, bool inclusive=true) |
| Skip all tokens between start and end, including start and end token.
|
|
void | skip_curly_block () |
| Skip all tokens between '{' and '}', including '{' and '}'.
|
|
void | skip_round_block () |
| Skip all tokens between '(' and ')', including '(' and ')'.
|
|
bool | parse_block (int start, int end) |
| Parse all tokens between start and end, including start and end token.
|
|
bool | parse_curly_block () |
| Parse all tokens between '{' and '}', including '{' and '}'.
|
|
bool | parse_round_block () |
| Parse all tokens between '(' and ')', including '(' and ')'.
|
|
bool | skip (int stop_token, bool inclusive=true) |
| Skip all tokens until a token with the given type is read.
|
|
bool | skip (int *stop_tokens, bool inclusive=true) |
| Skip all tokens until a token with one of the given types is read.
|
|
bool | is_in (int token_type, int *token_types) const |
| Check if the given token type is in the set of given token types.
|
|
|
enum | Grammar {
GRAMMAR_C
,
GRAMMAR_CPLUSPLUS
} |
|
typedef std::bitset< TOK_NO > | tokenset |
|
template<typename SYNTAX , typename RULE > |
static bool | seq (SYNTAX &s) |
| Parse a sequence of the given grammar rule by calling RULE::check() in a loop.
|
|
template<typename SYNTAX , typename RULE > |
static bool | list (SYNTAX &s, int sep, bool trailing_sep=false) |
| Parse a sequence of rule-separator pairs by calling RULE::check() in a loop.
|
|
template<typename SYNTAX , typename RULE > |
static bool | list (SYNTAX &s, int *separators, bool trailing_sep=false) |
| Parse a sequence of rule-separator pairs by calling RULE::check() in a loop.
|
|
template<class SYNTAX , class RULE > |
static bool | catch_error (SYNTAX &s, const char *msg, int *finish_tokens, int *skip_tokens) |
| Parse a grammar rule automatically catching parse errors.
|
|
template<class RULE1 , class RULE2 , class SYNTAX > |
static bool | ambiguous (SYNTAX &s) |
| First parse rule1 and if that rule fails discard all errors and parse the rule2.
|
|
TokenProvider * | token_provider |
| Token provider for getting the tokens to parse.
|
|
tokenset | _prim_types |
|
tokenset | _cv_quals |
|
tokenset | _class_spec_1 |
|
Token * | last_look_ahead_token |
|
bool | last_look_ahead_result |
|