GDB (xrefs)
Loading...
Searching...
No Matches
Public Member Functions | Public Attributes | Private Attributes | List of all members
parser_state Struct Reference

#include "parser-defs.h"

Inheritance diagram for parser_state:
expr_builder

Public Member Functions

 parser_state (const struct language_defn *lang, struct gdbarch *gdbarch, const struct block *context_block, CORE_ADDR context_pc, parser_flags flags, const char *input, bool completion, innermost_block_tracker *tracker)
 
 DISABLE_COPY_AND_ASSIGN (parser_state)
 
void start_arglist ()
 
int end_arglist ()
 
void mark_struct_expression (expr::structop_base_operation *op)
 
void mark_completion_tag (enum type_code tag, const char *ptr, int length)
 
void mark_completion (std::unique_ptr< expr_completion_base > completer)
 
void push (expr::operation_up &&op)
 
template<typename T , typename... Arg>
void push_new (Arg... args)
 
void push_c_string (int, struct stoken_vector *vec)
 
void push_symbol (const char *name, block_symbol sym)
 
void push_dollar (struct stoken str)
 
expr::operation_up pop ()
 
std::vector< expr::operation_uppop_vector (int n)
 
template<typename T >
void wrap ()
 
template<typename T >
void wrap2 ()
 
- Public Member Functions inherited from expr_builder
 expr_builder (const struct language_defn *lang, struct gdbarch *gdbarch)
 
 DISABLE_COPY_AND_ASSIGN (expr_builder)
 
ATTRIBUTE_UNUSED_RESULT expression_up release ()
 
struct gdbarchgdbarch ()
 
const struct language_defnlanguage ()
 
void set_operation (expr::operation_up &&op)
 

Public Attributes

const struct block *const expression_context_block
 
const CORE_ADDR expression_context_pc
 
const char * lexptr
 
const char * prev_lexptr = nullptr
 
int arglist_len = 0
 
std::unique_ptr< expr_completion_basem_completion_state
 
innermost_block_trackerblock_tracker
 
bool comma_terminates
 
bool parse_completion
 
bool void_context_p
 
bool debug
 
- Public Attributes inherited from expr_builder
expression_up expout
 

Private Attributes

std::vector< int > m_funcall_chain
 
std::vector< expr::operation_upm_operations
 

Detailed Description

Definition at line 138 of file parser-defs.h.

Constructor & Destructor Documentation

◆ parser_state()

parser_state::parser_state ( const struct language_defn * lang,
struct gdbarch * gdbarch,
const struct block * context_block,
CORE_ADDR context_pc,
parser_flags flags,
const char * input,
bool completion,
innermost_block_tracker * tracker )
inline

Definition at line 143 of file parser-defs.h.

Member Function Documentation

◆ DISABLE_COPY_AND_ASSIGN()

parser_state::DISABLE_COPY_AND_ASSIGN ( parser_state )

◆ end_arglist()

int parser_state::end_arglist ( )
inline

Definition at line 177 of file parser-defs.h.

References arglist_len, and m_funcall_chain.

Referenced by yyparse().

◆ mark_completion()

void parser_state::mark_completion ( std::unique_ptr< expr_completion_base > completer)
inline

Definition at line 198 of file parser-defs.h.

References m_completion_state.

Referenced by yyparse().

◆ mark_completion_tag()

void parser_state::mark_completion_tag ( enum type_code tag,
const char * ptr,
int length )

Definition at line 112 of file parse.c.

References m_completion_state, and parse_completion.

Referenced by yyparse().

◆ mark_struct_expression()

void parser_state::mark_struct_expression ( expr::structop_base_operation * op)

Definition at line 101 of file parse.c.

References m_completion_state, and parse_completion.

Referenced by rust_parser::parse_field(), write_var_or_type_completion(), and yyparse().

◆ pop()

expr::operation_up parser_state::pop ( )
inline

◆ pop_vector()

std::vector< expr::operation_up > parser_state::pop_vector ( int n)
inline

Definition at line 237 of file parser-defs.h.

References pop().

Referenced by ada_funcall(), end_msglist(), and yyparse().

◆ push()

void parser_state::push ( expr::operation_up && op)
inline

◆ push_c_string()

void parser_state::push_c_string ( int kind,
struct stoken_vector * vec )

Definition at line 126 of file parse.c.

References stoken_vector::len, typed_stoken::length, typed_stoken::ptr, and stoken_vector::tokens.

Referenced by yyparse().

◆ push_dollar()

void parser_state::push_dollar ( struct stoken str)

◆ push_new()

template<typename T , typename... Arg>
void parser_state::push_new ( Arg... args)
inline

◆ push_symbol()

void parser_state::push_symbol ( const char * name,
block_symbol sym )

◆ start_arglist()

void parser_state::start_arglist ( )
inline

Definition at line 168 of file parser-defs.h.

References arglist_len, and m_funcall_chain.

Referenced by yyparse().

◆ wrap()

template<typename T >
void parser_state::wrap ( )
inline

Definition at line 248 of file parser-defs.h.

References pop(), and push().

Referenced by wrap_unop_intrinsic(), and yyparse().

◆ wrap2()

template<typename T >
void parser_state::wrap2 ( )
inline

Definition at line 258 of file parser-defs.h.

References pop(), and push().

Referenced by wrap_binop_intrinsic(), and yyparse().

Member Data Documentation

◆ arglist_len

int parser_state::arglist_len = 0

Definition at line 288 of file parser-defs.h.

Referenced by end_arglist(), start_arglist(), and yyparse().

◆ block_tracker

innermost_block_tracker* parser_state::block_tracker

◆ comma_terminates

bool parser_state::comma_terminates

◆ debug

bool parser_state::debug

Definition at line 306 of file parser-defs.h.

Referenced by ada_parse(), c_parse(), d_parse(), f_language::parser(), and go_language::parser().

◆ expression_context_block

const struct block* const parser_state::expression_context_block

◆ expression_context_pc

const CORE_ADDR parser_state::expression_context_pc

Definition at line 275 of file parser-defs.h.

Referenced by c_parse().

◆ lexptr

const char* parser_state::lexptr

◆ m_completion_state

std::unique_ptr<expr_completion_base> parser_state::m_completion_state

◆ m_funcall_chain

std::vector<int> parser_state::m_funcall_chain
private

Definition at line 313 of file parser-defs.h.

Referenced by end_arglist(), and start_arglist().

◆ m_operations

std::vector<expr::operation_up> parser_state::m_operations
private

Definition at line 316 of file parser-defs.h.

Referenced by pop(), push(), and push_new().

◆ parse_completion

bool parser_state::parse_completion

◆ prev_lexptr

const char* parser_state::prev_lexptr = nullptr

◆ void_context_p

bool parser_state::void_context_p

Definition at line 303 of file parser-defs.h.

Referenced by ada_parse().


The documentation for this struct was generated from the following files: