projects
/
binutils-gdb.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Enable async mode in the target in attach_cmd.
[binutils-gdb.git]
/
gdb
/
c-exp.y
diff --git
a/gdb/c-exp.y
b/gdb/c-exp.y
index 22cd50ab1e24ce3cf2f057ad7441f55529ac3277..de29d2f70e239efe9437ef5b103ecaf16c18955d 100644
(file)
--- a/
gdb/c-exp.y
+++ b/
gdb/c-exp.y
@@
-1,5
+1,5
@@
/* YACC parser for C expressions, for GDB.
/* YACC parser for C expressions, for GDB.
- Copyright (C) 1986-202
1
Free Software Foundation, Inc.
+ Copyright (C) 1986-202
2
Free Software Foundation, Inc.
This file is part of GDB.
This file is part of GDB.
@@
-1093,7
+1093,7
@@
block : block COLONCOLON name
= lookup_symbol (copy.c_str (), $1,
VAR_DOMAIN, NULL).symbol;
= lookup_symbol (copy.c_str (), $1,
VAR_DOMAIN, NULL).symbol;
- if (!tem ||
SYMBOL_CLASS (tem
) != LOC_BLOCK)
+ if (!tem ||
tem->aclass (
) != LOC_BLOCK)
error (_("No function \"%s\" in specified context."),
copy.c_str ());
$$ = SYMBOL_BLOCK_VALUE (tem); }
error (_("No function \"%s\" in specified context."),
copy.c_str ());
$$ = SYMBOL_BLOCK_VALUE (tem); }
@@
-1102,7
+1102,7
@@
block : block COLONCOLON name
variable: name_not_typename ENTRY
{ struct symbol *sym = $1.sym.symbol;
variable: name_not_typename ENTRY
{ struct symbol *sym = $1.sym.symbol;
- if (sym == NULL || !
SYMBOL_IS_ARGUMENT (sym
)
+ if (sym == NULL || !
sym->is_argument (
)
|| !symbol_read_needs_frame (sym))
error (_("@entry can be used only for function "
"parameters, not for \"%s\""),
|| !symbol_read_needs_frame (sym))
error (_("@entry can be used only for function "
"parameters, not for \"%s\""),
@@
-1780,11
+1780,11
@@
oper: OPERATOR NEW
| OPERATOR OBJC_LBRAC ']'
{ $$ = operator_stoken ("[]"); }
| OPERATOR conversion_type_id
| OPERATOR OBJC_LBRAC ']'
{ $$ = operator_stoken ("[]"); }
| OPERATOR conversion_type_id
- {
string_file buf;
-
+ {
+ string_file buf;
c_print_type ($2, NULL, &buf, -1, 0,
&type_print_raw_options);
c_print_type ($2, NULL, &buf, -1, 0,
&type_print_raw_options);
- std::string name =
std::move (buf.string ()
);
+ std::string name =
buf.release (
);
/* This also needs canonicalization. */
gdb::unique_xmalloc_ptr<char> canon
/* This also needs canonicalization. */
gdb::unique_xmalloc_ptr<char> canon
@@
-3067,7
+3067,7
@@
classify_name (struct parser_state *par_state, const struct block *block,
par_state->language ()->name_of_this ()
? &is_a_field_of_this : NULL);
par_state->language ()->name_of_this ()
? &is_a_field_of_this : NULL);
- if (bsym.symbol &&
SYMBOL_CLASS (bsym.symbol
) == LOC_BLOCK)
+ if (bsym.symbol &&
bsym.symbol->aclass (
) == LOC_BLOCK)
{
yylval.ssym.sym = bsym;
yylval.ssym.is_a_field_of_this = is_a_field_of_this.type != NULL;
{
yylval.ssym.sym = bsym;
yylval.ssym.is_a_field_of_this = is_a_field_of_this.type != NULL;
@@
-3090,7
+3090,7
@@
classify_name (struct parser_state *par_state, const struct block *block,
&inner_is_a_field_of_this);
if (bsym.symbol != NULL)
{
&inner_is_a_field_of_this);
if (bsym.symbol != NULL)
{
- yylval.tsym.type =
SYMBOL_TYPE (bsym.symbol
);
+ yylval.tsym.type =
bsym.symbol->type (
);
return TYPENAME;
}
}
return TYPENAME;
}
}
@@
-3109,16
+3109,16
@@
classify_name (struct parser_state *par_state, const struct block *block,
symtab = lookup_symtab (copy.c_str ());
if (symtab)
{
symtab = lookup_symtab (copy.c_str ());
if (symtab)
{
- yylval.bval = BLOCKVECTOR_BLOCK (
SYMTAB_BLOCKVECTOR (symtab
),
+ yylval.bval = BLOCKVECTOR_BLOCK (
symtab->blockvector (
),
STATIC_BLOCK);
return FILENAME;
}
}
}
STATIC_BLOCK);
return FILENAME;
}
}
}
- if (bsym.symbol &&
SYMBOL_CLASS (bsym.symbol
) == LOC_TYPEDEF)
+ if (bsym.symbol &&
bsym.symbol->aclass (
) == LOC_TYPEDEF)
{
{
- yylval.tsym.type =
SYMBOL_TYPE (bsym.symbol
);
+ yylval.tsym.type =
bsym.symbol->type (
);
return TYPENAME;
}
return TYPENAME;
}
@@
-3135,7
+3135,7
@@
classify_name (struct parser_state *par_state, const struct block *block,
sym = lookup_struct_typedef (copy.c_str (),
par_state->expression_context_block, 1);
if (sym)
sym = lookup_struct_typedef (copy.c_str (),
par_state->expression_context_block, 1);
if (sym)
- yylval.theclass.type =
SYMBOL_TYPE (sym
);
+ yylval.theclass.type =
sym->type (
);
return CLASSNAME;
}
}
return CLASSNAME;
}
}
@@
-3211,7
+3211,7
@@
classify_inner_name (struct parser_state *par_state,
return ERROR;
}
return ERROR;
}
- switch (
SYMBOL_CLASS (yylval.ssym.sym.symbol
))
+ switch (
yylval.ssym.sym.symbol->aclass (
))
{
case LOC_BLOCK:
case LOC_LABEL:
{
case LOC_BLOCK:
case LOC_LABEL:
@@
-3231,7
+3231,7
@@
classify_inner_name (struct parser_state *par_state,
return ERROR;
case LOC_TYPEDEF:
return ERROR;
case LOC_TYPEDEF:
- yylval.tsym.type =
SYMBOL_TYPE (yylval.ssym.sym.symbol
);
+ yylval.tsym.type =
yylval.ssym.sym.symbol->type (
);
return TYPENAME;
default:
return TYPENAME;
default: