GDB (xrefs)
Loading...
Searching...
No Matches
Classes | Macros | Enumerations | Functions | Variables
linespec.c File Reference
#include "defs.h"
#include "symtab.h"
#include "frame.h"
#include "command.h"
#include "symfile.h"
#include "objfiles.h"
#include "source.h"
#include "demangle.h"
#include "value.h"
#include "completer.h"
#include "cp-abi.h"
#include "cp-support.h"
#include "parser-defs.h"
#include "block.h"
#include "objc-lang.h"
#include "linespec.h"
#include "language.h"
#include "interps.h"
#include "mi/mi-cmds.h"
#include "target.h"
#include "arch-utils.h"
#include <ctype.h>
#include "cli/cli-utils.h"
#include "filenames.h"
#include "ada-lang.h"
#include "stack.h"
#include "location.h"
#include "gdbsupport/function-view.h"
#include "gdbsupport/def-vector.h"
#include <algorithm>
#include "inferior.h"

Go to the source code of this file.

Classes

struct  address_entry
 
struct  linespec
 
struct  linespec_canonical_name
 
struct  linespec_state
 
struct  collect_info
 
struct  symbol_searcher_collect_info
 
struct  linespec_token
 
struct  linespec_parser
 
struct  linespec_parser::state
 
struct  decode_line_2_item
 

Macros

#define IF_KEYWORD_INDEX   0
 
#define FORCE_KEYWORD_INDEX   4
 
#define LS_TOKEN_STOKEN(TOK)   (TOK).data.string
 
#define LS_TOKEN_KEYWORD(TOK)   (TOK).data.keyword
 
#define PARSER_STREAM(P)   ((P)->lexer.stream)
 
#define PARSER_STATE(PPTR)   (&(PPTR)->state)
 
#define PARSER_RESULT(PPTR)   (&(PPTR)->result)
 
#define PARSER_EXPLICIT(PPTR)   (&PARSER_RESULT ((PPTR))->explicit_loc)
 

Enumerations

enum class  linespec_complete_what {
  NOTHING , FUNCTION , LABEL , EXPRESSION ,
  KEYWORD
}
 
enum  linespec_token_type {
  LSTOKEN_KEYWORD = 0 , LSTOKEN_COLON , LSTOKEN_STRING , LSTOKEN_NUMBER ,
  LSTOKEN_COMMA , LSTOKEN_EOI , LSTOKEN_CONSUMED
}
 

Functions

static void iterate_over_file_blocks (struct symtab *symtab, const lookup_name_info &name, domain_enum domain, gdb::function_view< symbol_found_callback_ftype > callback)
 
static void initialize_defaults (struct symtab **default_symtab, int *default_line)
 
CORE_ADDR linespec_expression_to_pc (const char **exp_ptr)
 
static std::vector< symtab_and_linedecode_objc (struct linespec_state *self, linespec *ls, const char *arg)
 
static std::vector< symtab * > symtabs_from_filename (const char *, struct program_space *pspace)
 
static std::vector< block_symbolfind_label_symbols (struct linespec_state *self, const std::vector< block_symbol > &function_symbols, std::vector< block_symbol > *label_funcs_ret, const char *name, bool completion_mode=false)
 
static void find_linespec_symbols (struct linespec_state *self, const std::vector< symtab * > &file_symtabs, const char *name, symbol_name_match_type name_match_type, std::vector< block_symbol > *symbols, std::vector< bound_minimal_symbol > *minsyms)
 
static struct line_offset linespec_parse_variable (struct linespec_state *self, const char *variable)
 
static int symbol_to_sal (struct symtab_and_line *result, int funfirstline, struct symbol *sym)
 
static void add_matching_symbols_to_info (const char *name, symbol_name_match_type name_match_type, enum search_domain search_domain, struct collect_info *info, struct program_space *pspace)
 
static void add_all_symbol_names_from_pspace (struct collect_info *info, struct program_space *pspace, const std::vector< const char * > &names, enum search_domain search_domain)
 
static std::vector< symtab * > collect_symtabs_from_filename (const char *file, struct program_space *pspace)
 
static std::vector< symtab_and_linedecode_digits_ordinary (struct linespec_state *self, linespec *ls, int line, const linetable_entry **best_entry)
 
static std::vector< symtab_and_linedecode_digits_list_mode (struct linespec_state *self, linespec *ls, struct symtab_and_line val)
 
static void minsym_found (struct linespec_state *self, struct objfile *objfile, struct minimal_symbol *msymbol, std::vector< symtab_and_line > *result)
 
static bool compare_symbols (const block_symbol &a, const block_symbol &b)
 
static bool compare_msymbols (const bound_minimal_symbol &a, const bound_minimal_symbol &b)
 
static int linespec_lexer_lex_number (linespec_parser *parser, linespec_token *tokenp)
 
const char * linespec_lexer_lex_keyword (const char *p)
 
int is_ada_operator (const char *string)
 
static const char * skip_quote_char (const char *string, char quote_char)
 
static gdb::unique_xmalloc_ptr< char > copy_token_string (linespec_token token)
 
static int is_closing_quote_enclosed (const char *p)
 
static const char * find_parameter_list_end (const char *input)
 
static size_t string_find_incomplete_keyword_at_end (const char *const *keywords, const char *string, size_t string_len)
 
static linespec_token linespec_lexer_lex_string (linespec_parser *parser)
 
static linespec_token linespec_lexer_lex_one (linespec_parser *parser)
 
static linespec_token linespec_lexer_consume_token (linespec_parser *parser)
 
static linespec_token linespec_lexer_peek_token (linespec_parser *parser)
 
static void add_sal_to_sals (struct linespec_state *self, std::vector< symtab_and_line > *sals, struct symtab_and_line *sal, const char *symname, int literal_canonical)
 
static hashval_t hash_address_entry (const void *p)
 
static int eq_address_entry (const void *a, const void *b)
 
static int maybe_add_address (htab_t set, struct program_space *pspace, CORE_ADDR addr)
 
static void iterate_over_all_matching_symtabs (struct linespec_state *state, const lookup_name_info &lookup_name, const domain_enum name_domain, enum search_domain search_domain, struct program_space *search_pspace, bool include_inline, gdb::function_view< symbol_found_callback_ftype > callback)
 
static const struct blockget_current_search_block (void)
 
static void find_methods (struct type *t, enum language t_lang, const char *name, std::vector< const char * > *result_names, std::vector< struct type * > *superclasses)
 
static const char * find_toplevel_string (const char *haystack, const char *needle)
 
static std::string canonical_to_fullform (const struct linespec_canonical_name *canonical)
 
static void filter_results (struct linespec_state *self, std::vector< symtab_and_line > *result, const std::vector< const char * > &filters)
 
static void convert_results_to_lsals (struct linespec_state *self, std::vector< symtab_and_line > *result)
 
static bool decode_line_2_compare_items (const decode_line_2_item &a, const decode_line_2_item &b)
 
static void decode_line_2 (struct linespec_state *self, std::vector< symtab_and_line > *result, const char *select_mode)
 
static void ATTRIBUTE_NORETURN symbol_not_found_error (const char *symbol, const char *filename)
 
static void ATTRIBUTE_NORETURN unexpected_linespec_error (linespec_parser *parser)
 
static void ATTRIBUTE_NORETURN undefined_label_error (const char *function, const char *label)
 
static void ATTRIBUTE_NORETURN source_file_not_found_error (const char *name)
 
static linespec_token save_stream_and_consume_token (linespec_parser *parser)
 
struct line_offset linespec_parse_line_offset (const char *string)
 
static void set_completion_after_number (linespec_parser *parser, linespec_complete_what next)
 
static void linespec_parse_basic (linespec_parser *parser)
 
static void canonicalize_linespec (struct linespec_state *state, const linespec *ls)
 
static std::vector< symtab_and_linecreate_sals_line_offset (struct linespec_state *self, linespec *ls)
 
static std::vector< symtab_and_lineconvert_address_location_to_sals (struct linespec_state *self, CORE_ADDR address)
 
static std::vector< symtab_and_lineconvert_linespec_to_sals (struct linespec_state *state, linespec *ls)
 
static void convert_explicit_location_spec_to_linespec (struct linespec_state *self, linespec *result, const char *source_filename, const char *function_name, symbol_name_match_type fname_match_type, const char *label_name, struct line_offset line_offset)
 
static std::vector< symtab_and_lineconvert_explicit_location_spec_to_sals (struct linespec_state *self, linespec *result, const explicit_location_spec *explicit_spec)
 
static std::vector< symtab_and_lineparse_linespec (linespec_parser *parser, const char *arg, symbol_name_match_type match_type)
 
static void linespec_state_constructor (struct linespec_state *self, int flags, const struct language_defn *language, struct program_space *search_pspace, struct symtab *default_symtab, int default_line, struct linespec_result *canonical)
 
static void linespec_state_destructor (struct linespec_state *self)
 
void linespec_lex_to_end (const char **stringp)
 
void linespec_complete_function (completion_tracker &tracker, const char *function, symbol_name_match_type func_match_type, const char *source_filename)
 
static void complete_linespec_component (linespec_parser *parser, completion_tracker &tracker, const char *text, linespec_complete_what component, const char *source_filename)
 
static void complete_label (completion_tracker &tracker, linespec_parser *parser, const char *label_name)
 
void linespec_complete_label (completion_tracker &tracker, const struct language_defn *language, const char *source_filename, const char *function_name, symbol_name_match_type func_name_match_type, const char *label_name)
 
void linespec_complete (completion_tracker &tracker, const char *text, symbol_name_match_type match_type)
 
static std::vector< symtab_and_linelocation_spec_to_sals (linespec_parser *parser, const location_spec *locspec)
 
void decode_line_full (struct location_spec *locspec, int flags, struct program_space *search_pspace, struct symtab *default_symtab, int default_line, struct linespec_result *canonical, const char *select_mode, const char *filter)
 
std::vector< symtab_and_linedecode_line_1 (const location_spec *locspec, int flags, struct program_space *search_pspace, struct symtab *default_symtab, int default_line)
 
std::vector< symtab_and_linedecode_line_with_current_source (const char *string, int flags)
 
std::vector< symtab_and_linedecode_line_with_last_displayed (const char *string, int flags)
 
static std::vector< block_symbollookup_prefix_sym (struct linespec_state *state, const std::vector< symtab * > &file_symtabs, const char *class_name)
 
static void add_all_symbol_names_from_pspace (struct collect_info *info, struct program_space *pspace, const std::vector< const char * > &names, enum search_domain search_domain)
 
static void find_superclass_methods (std::vector< struct type * > &&superclasses, const char *name, enum language name_lang, std::vector< const char * > *result_names)
 
static void find_method (struct linespec_state *self, const std::vector< symtab * > &file_symtabs, const char *class_name, const char *method_name, std::vector< block_symbol > *sym_classes, std::vector< block_symbol > *symbols, std::vector< bound_minimal_symbol > *minsyms)
 
static void find_function_symbols (struct linespec_state *state, const std::vector< symtab * > &file_symtabs, const char *name, symbol_name_match_type name_match_type, std::vector< block_symbol > *symbols, std::vector< bound_minimal_symbol > *minsyms)
 
static void find_label_symbols_in_block (const struct block *block, const char *name, struct symbol *fn_sym, bool completion_mode, std::vector< block_symbol > *result, std::vector< block_symbol > *label_funcs_ret)
 
static void add_minsym (struct minimal_symbol *minsym, struct objfile *objfile, struct symtab *symtab, int list_mode, std::vector< struct bound_minimal_symbol > *msyms)
 
static void search_minsyms_for_name (struct collect_info *info, const lookup_name_info &name, struct program_space *search_pspace, struct symtab *symtab)
 
static void add_matching_symbols_to_info (const char *name, symbol_name_match_type name_match_type, enum search_domain search_domain, struct collect_info *info, struct program_space *pspace)
 
const char * get_gdb_linespec_parser_quote_characters (void)
 

Variables

const char *const linespec_keywords [] = { "if", "thread", "task", "inferior", "-force-condition", NULL }
 
static const char linespec_quote_characters [] = "\"\'"
 

Macro Definition Documentation

◆ FORCE_KEYWORD_INDEX

#define FORCE_KEYWORD_INDEX   4

Definition at line 259 of file linespec.c.

Referenced by linespec_lexer_lex_keyword().

◆ IF_KEYWORD_INDEX

#define IF_KEYWORD_INDEX   0

Definition at line 258 of file linespec.c.

Referenced by linespec_lexer_lex_keyword().

◆ LS_TOKEN_KEYWORD

#define LS_TOKEN_KEYWORD ( TOK)    (TOK).data.keyword

Definition at line 280 of file linespec.c.

Referenced by copy_token_string(), and linespec_lexer_lex_one().

◆ LS_TOKEN_STOKEN

#define LS_TOKEN_STOKEN ( TOK)    (TOK).data.string

◆ PARSER_EXPLICIT

#define PARSER_EXPLICIT ( PPTR)    (&PARSER_RESULT ((PPTR))->explicit_loc)

◆ PARSER_RESULT

#define PARSER_RESULT ( PPTR)    (&(PPTR)->result)

◆ PARSER_STATE

#define PARSER_STATE ( PPTR)    (&(PPTR)->state)

◆ PARSER_STREAM

#define PARSER_STREAM ( P)    ((P)->lexer.stream)

Enumeration Type Documentation

◆ linespec_complete_what

enum class linespec_complete_what
strong
Enumerator
NOTHING 
FUNCTION 
LABEL 
EXPRESSION 
KEYWORD 

Definition at line 55 of file linespec.c.

◆ linespec_token_type

Enumerator
LSTOKEN_KEYWORD 
LSTOKEN_COLON 
LSTOKEN_STRING 
LSTOKEN_NUMBER 
LSTOKEN_COMMA 
LSTOKEN_EOI 
LSTOKEN_CONSUMED 

Definition at line 231 of file linespec.c.

Function Documentation

◆ add_all_symbol_names_from_pspace() [1/2]

static void add_all_symbol_names_from_pspace ( struct collect_info * info,
struct program_space * pspace,
const std::vector< const char * > & names,
enum search_domain search_domain )
static

◆ add_all_symbol_names_from_pspace() [2/2]

static void add_all_symbol_names_from_pspace ( struct collect_info * info,
struct program_space * pspace,
const std::vector< const char * > & names,
enum search_domain search_domain )
static

Definition at line 3523 of file linespec.c.

References add_matching_symbols_to_info(), and FULL.

◆ add_matching_symbols_to_info() [1/2]

static void add_matching_symbols_to_info ( const char * name,
symbol_name_match_type name_match_type,
enum search_domain search_domain,
struct collect_info * info,
struct program_space * pspace )
static

◆ add_matching_symbols_to_info() [2/2]

static void add_matching_symbols_to_info ( const char * name,
symbol_name_match_type name_match_type,
enum search_domain search_domain,
struct collect_info * info,
struct program_space * pspace )
static

◆ add_minsym()

static void add_minsym ( struct minimal_symbol * minsym,
struct objfile * objfile,
struct symtab * symtab,
int list_mode,
std::vector< struct bound_minimal_symbol > * msyms )
static

Definition at line 4173 of file linespec.c.

References find_pc_sect_line(), msymbol_is_function(), and symtab_and_line::symtab.

Referenced by search_minsyms_for_name().

◆ add_sal_to_sals()

static void add_sal_to_sals ( struct linespec_state * self,
std::vector< symtab_and_line > * sals,
struct symtab_and_line * sal,
const char * symname,
int literal_canonical )
static

◆ canonical_to_fullform()

static std::string canonical_to_fullform ( const struct linespec_canonical_name * canonical)
static

◆ canonicalize_linespec()

static void canonicalize_linespec ( struct linespec_state * state,
const linespec * ls )
static

◆ collect_symtabs_from_filename()

static std::vector< symtab * > collect_symtabs_from_filename ( const char * file,
struct program_space * pspace )
static

◆ compare_msymbols()

static bool compare_msymbols ( const bound_minimal_symbol & a,
const bound_minimal_symbol & b )
static

◆ compare_symbols()

static bool compare_symbols ( const block_symbol & a,
const block_symbol & b )
static

◆ complete_label()

static void complete_label ( completion_tracker & tracker,
linespec_parser * parser,
const char * label_name )
static

◆ complete_linespec_component()

static void complete_linespec_component ( linespec_parser * parser,
completion_tracker & tracker,
const char * text,
linespec_complete_what component,
const char * source_filename )
static

◆ convert_address_location_to_sals()

static std::vector< symtab_and_line > convert_address_location_to_sals ( struct linespec_state * self,
CORE_ADDR address )
static

◆ convert_explicit_location_spec_to_linespec()

static void convert_explicit_location_spec_to_linespec ( struct linespec_state * self,
linespec * result,
const char * source_filename,
const char * function_name,
symbol_name_match_type fname_match_type,
const char * label_name,
struct line_offset line_offset )
static

◆ convert_explicit_location_spec_to_sals()

static std::vector< symtab_and_line > convert_explicit_location_spec_to_sals ( struct linespec_state * self,
linespec * result,
const explicit_location_spec * explicit_spec )
static

◆ convert_linespec_to_sals()

static std::vector< symtab_and_line > convert_linespec_to_sals ( struct linespec_state * state,
linespec * ls )
static

◆ convert_results_to_lsals()

static void convert_results_to_lsals ( struct linespec_state * self,
std::vector< symtab_and_line > * result )
static

◆ copy_token_string()

static gdb::unique_xmalloc_ptr< char > copy_token_string ( linespec_token token)
static

◆ create_sals_line_offset()

static std::vector< symtab_and_line > create_sals_line_offset ( struct linespec_state * self,
linespec * ls )
static

◆ decode_digits_list_mode()

static std::vector< symtab_and_line > decode_digits_list_mode ( struct linespec_state * self,
linespec * ls,
struct symtab_and_line val )
static

◆ decode_digits_ordinary()

static std::vector< symtab_and_line > decode_digits_ordinary ( struct linespec_state * self,
linespec * ls,
int line,
const linetable_entry ** best_entry )
static

◆ decode_line_1()

std::vector< symtab_and_line > decode_line_1 ( const location_spec * locspec,
int flags,
struct program_space * search_pspace,
struct symtab * default_symtab,
int default_line )

◆ decode_line_2()

static void decode_line_2 ( struct linespec_state * self,
std::vector< symtab_and_line > * result,
const char * select_mode )
static

◆ decode_line_2_compare_items()

static bool decode_line_2_compare_items ( const decode_line_2_item & a,
const decode_line_2_item & b )
static

Definition at line 1419 of file linespec.c.

References decode_line_2_item::displayform, and decode_line_2_item::fullform.

Referenced by decode_line_2().

◆ decode_line_full()

void decode_line_full ( struct location_spec * locspec,
int flags,
struct program_space * search_pspace,
struct symtab * default_symtab,
int default_line,
struct linespec_result * canonical,
const char * select_mode,
const char * filter )

◆ decode_line_with_current_source()

std::vector< symtab_and_line > decode_line_with_current_source ( const char * string,
int flags )

◆ decode_line_with_last_displayed()

std::vector< symtab_and_line > decode_line_with_last_displayed ( const char * string,
int flags )

◆ decode_objc()

static std::vector< symtab_and_line > decode_objc ( struct linespec_state * self,
linespec * ls,
const char * arg )
static

◆ eq_address_entry()

static int eq_address_entry ( const void * a,
const void * b )
static

Definition at line 1116 of file linespec.c.

References address_entry::addr, and address_entry::pspace.

Referenced by linespec_state_constructor().

◆ filter_results()

static void filter_results ( struct linespec_state * self,
std::vector< symtab_and_line > * result,
const std::vector< const char * > & filters )
static

◆ find_function_symbols()

static void find_function_symbols ( struct linespec_state * state,
const std::vector< symtab * > & file_symtabs,
const char * name,
symbol_name_match_type name_match_type,
std::vector< block_symbol > * symbols,
std::vector< bound_minimal_symbol > * minsyms )
static

◆ find_label_symbols()

static std::vector< block_symbol > find_label_symbols ( struct linespec_state * self,
const std::vector< block_symbol > & function_symbols,
std::vector< block_symbol > * label_funcs_ret,
const char * name,
bool completion_mode = false )
static

◆ find_label_symbols_in_block()

static void find_label_symbols_in_block ( const struct block * block,
const char * name,
struct symbol * fn_sym,
bool completion_mode,
std::vector< block_symbol > * result,
std::vector< block_symbol > * label_funcs_ret )
static

◆ find_linespec_symbols()

static void find_linespec_symbols ( struct linespec_state * self,
const std::vector< symtab * > & file_symtabs,
const char * name,
symbol_name_match_type name_match_type,
std::vector< block_symbol > * symbols,
std::vector< bound_minimal_symbol > * minsyms )
static

◆ find_method()

static void find_method ( struct linespec_state * self,
const std::vector< symtab * > & file_symtabs,
const char * class_name,
const char * method_name,
std::vector< block_symbol > * sym_classes,
std::vector< block_symbol > * symbols,
std::vector< bound_minimal_symbol > * minsyms )
static

◆ find_methods()

static void find_methods ( struct type * t,
enum language t_lang,
const char * name,
std::vector< const char * > * result_names,
std::vector< struct type * > * superclasses )
static

◆ find_parameter_list_end()

static const char * find_parameter_list_end ( const char * input)
static

Definition at line 607 of file linespec.c.

Referenced by linespec_lexer_lex_string().

◆ find_superclass_methods()

static void find_superclass_methods ( std::vector< struct type * > && superclasses,
const char * name,
enum language name_lang,
std::vector< const char * > * result_names )
static

Definition at line 3535 of file linespec.c.

References find_methods(), and name.

Referenced by find_method().

◆ find_toplevel_string()

static const char * find_toplevel_string ( const char * haystack,
const char * needle )
static

Definition at line 1304 of file linespec.c.

References find_toplevel_char().

Referenced by find_linespec_symbols().

◆ get_current_search_block()

static const struct block * get_current_search_block ( void )
static

Definition at line 1216 of file linespec.c.

References get_selected_block().

Referenced by find_label_symbols().

◆ get_gdb_linespec_parser_quote_characters()

const char * get_gdb_linespec_parser_quote_characters ( void )

◆ hash_address_entry()

static hashval_t hash_address_entry ( const void * p)
static

Definition at line 1104 of file linespec.c.

References address_entry::addr, and address_entry::pspace.

Referenced by linespec_state_constructor().

◆ initialize_defaults()

static void initialize_defaults ( struct symtab ** default_symtab,
int * default_line )
static

◆ is_ada_operator()

int is_ada_operator ( const char * string)

◆ is_closing_quote_enclosed()

static int is_closing_quote_enclosed ( const char * p)
static

◆ iterate_over_all_matching_symtabs()

static void iterate_over_all_matching_symtabs ( struct linespec_state * state,
const lookup_name_info & lookup_name,
const domain_enum name_domain,
enum search_domain search_domain,
struct program_space * search_pspace,
bool include_inline,
gdb::function_view< symbol_found_callback_ftype > callback )
static

◆ iterate_over_file_blocks()

static void iterate_over_file_blocks ( struct symtab * symtab,
const lookup_name_info & name,
domain_enum domain,
gdb::function_view< symbol_found_callback_ftype > callback )
static

◆ linespec_complete()

void linespec_complete ( completion_tracker & tracker,
const char * text,
symbol_name_match_type match_type )

◆ linespec_complete_function()

void linespec_complete_function ( completion_tracker & tracker,
const char * function,
symbol_name_match_type func_match_type,
const char * source_filename )

◆ linespec_complete_label()

void linespec_complete_label ( completion_tracker & tracker,
const struct language_defn * language,
const char * source_filename,
const char * function_name,
symbol_name_match_type func_name_match_type,
const char * label_name )

◆ linespec_expression_to_pc()

CORE_ADDR linespec_expression_to_pc ( const char ** exp_ptr)

◆ linespec_lex_to_end()

void linespec_lex_to_end ( const char ** stringp)

◆ linespec_lexer_consume_token()

static linespec_token linespec_lexer_consume_token ( linespec_parser * parser)
static

◆ linespec_lexer_lex_keyword()

const char * linespec_lexer_lex_keyword ( const char * p)

◆ linespec_lexer_lex_number()

static int linespec_lexer_lex_number ( linespec_parser * parser,
linespec_token * tokenp )
static

◆ linespec_lexer_lex_one()

static linespec_token linespec_lexer_lex_one ( linespec_parser * parser)
static

◆ linespec_lexer_lex_string()

static linespec_token linespec_lexer_lex_string ( linespec_parser * parser)
static

◆ linespec_lexer_peek_token()

static linespec_token linespec_lexer_peek_token ( linespec_parser * parser)
static

◆ linespec_parse_basic()

static void linespec_parse_basic ( linespec_parser * parser)
static

◆ linespec_parse_line_offset()

struct line_offset linespec_parse_line_offset ( const char * string)

◆ linespec_parse_variable()

static struct line_offset linespec_parse_variable ( struct linespec_state * self,
const char * variable )
static

◆ linespec_state_constructor()

static void linespec_state_constructor ( struct linespec_state * self,
int flags,
const struct language_defn * language,
struct program_space * search_pspace,
struct symtab * default_symtab,
int default_line,
struct linespec_result * canonical )
static

◆ linespec_state_destructor()

static void linespec_state_destructor ( struct linespec_state * self)
static

◆ location_spec_to_sals()

static std::vector< symtab_and_line > location_spec_to_sals ( linespec_parser * parser,
const location_spec * locspec )
static

◆ lookup_prefix_sym()

static std::vector< block_symbol > lookup_prefix_sym ( struct linespec_state * state,
const std::vector< symtab * > & file_symtabs,
const char * class_name )
static

◆ maybe_add_address()

static int maybe_add_address ( htab_t set,
struct program_space * pspace,
CORE_ADDR addr )
static

Definition at line 1129 of file linespec.c.

References address_entry::addr, and address_entry::pspace.

Referenced by convert_linespec_to_sals(), and minsym_found().

◆ minsym_found()

static void minsym_found ( struct linespec_state * self,
struct objfile * objfile,
struct minimal_symbol * msymbol,
std::vector< symtab_and_line > * result )
static

◆ parse_linespec()

static std::vector< symtab_and_line > parse_linespec ( linespec_parser * parser,
const char * arg,
symbol_name_match_type match_type )
static

◆ save_stream_and_consume_token()

static linespec_token save_stream_and_consume_token ( linespec_parser * parser)
static

◆ search_minsyms_for_name()

static void search_minsyms_for_name ( struct collect_info * info,
const lookup_name_info & name,
struct program_space * search_pspace,
struct symtab * symtab )
static

◆ set_completion_after_number()

static void set_completion_after_number ( linespec_parser * parser,
linespec_complete_what next )
static

◆ skip_quote_char()

static const char * skip_quote_char ( const char * string,
char quote_char )
static

Definition at line 559 of file linespec.c.

References find_toplevel_char().

Referenced by linespec_lexer_lex_string(), and parse_linespec().

◆ source_file_not_found_error()

static void ATTRIBUTE_NORETURN source_file_not_found_error ( const char * name)
static

Definition at line 1645 of file linespec.c.

References name.

Referenced by convert_explicit_location_spec_to_linespec(), and symtabs_from_filename().

◆ string_find_incomplete_keyword_at_end()

static size_t string_find_incomplete_keyword_at_end ( const char *const * keywords,
const char * string,
size_t string_len )
static

Definition at line 646 of file linespec.c.

Referenced by linespec_complete().

◆ symbol_not_found_error()

static void ATTRIBUTE_NORETURN symbol_not_found_error ( const char * symbol,
const char * filename )
static

◆ symbol_to_sal()

static int symbol_to_sal ( struct symtab_and_line * result,
int funfirstline,
struct symbol * sym )
static

◆ symtabs_from_filename()

static std::vector< symtab * > symtabs_from_filename ( const char * filename,
struct program_space * pspace )
static

◆ undefined_label_error()

static void ATTRIBUTE_NORETURN undefined_label_error ( const char * function,
const char * label )
static

◆ unexpected_linespec_error()

static void ATTRIBUTE_NORETURN unexpected_linespec_error ( linespec_parser * parser)
static

Variable Documentation

◆ linespec_keywords

const char* const linespec_keywords[] = { "if", "thread", "task", "inferior", "-force-condition", NULL }

◆ linespec_quote_characters

const char linespec_quote_characters[] = "\"\'"
static