66 int assign_modify = 0;
122 const struct block *b;
137 case OP_VAR_MSYM_VALUE:
144 case OP_FUNC_STATIC_VAR:
152 case OP_VAR_ENTRY_VALUE:
193 for (tem = 0; tem < nargs; tem++)
224 case OP_OBJC_NSSTRING:
240 case OP_OBJC_MSGCALL:
251 error (
_(
"bad selector"));
258 s = (
char *) alloca (strlen (
selector) + 1);
260 for (tem = 0; tem < nargs; tem++)
262 nextS = strchr (s,
':');
298 tempstr = (
char *) alloca (nargs);
325 (
gdb_byte *) tempstr, nargs - 1, NULL, 0, &opts);
331 for (tem = 0; tem < nargs; tem++)
368 case STRUCTOP_STRUCT:
385 case STRUCTOP_MEMBER:
397 case BINOP_SUBSCRIPT:
404 case UNOP_POSTINCREMENT:
409 case UNOP_POSTDECREMENT:
437 case UNOP_DYNAMIC_CAST:
438 case UNOP_REINTERPRET_CAST:
440 :
"reinterpret_cast", stream);
478 case UNOP_MEMVAL_TYPE:
489 case BINOP_ASSIGN_MODIFY:
496 for (tem = 0; op_print_tab[tem].
opcode != OP_NULL; tem++)
497 if (op_print_tab[tem].opcode == opcode)
499 op_str = op_print_tab[tem].
string;
502 if (op_print_tab[tem].opcode != opcode)
505 error (
_(
"Invalid expression"));
521 case MULTI_SUBSCRIPT:
526 for (tem = 0; tem < nargs; tem++)
546 type_instance_flags
flags 599 for (tem = 0; op_print_tab[tem].
opcode != OP_NULL; tem++)
600 if (op_print_tab[tem].opcode == opcode)
602 op_str = op_print_tab[tem].
string;
607 if (op_print_tab[tem].opcode != opcode)
611 error (
_(
"Invalid expression"));
615 if ((
int) myprec < (
int) prec)
617 if ((
int) opcode > (
int) BINOP_END)
647 else if (op_str[0] ==
',')
658 if ((
int) myprec < (
int) prec)
669 const struct op_print *op_print_tab;
672 for (tem = 0; op_print_tab[tem].
opcode != OP_NULL; tem++)
673 if (op_print_tab[tem].
opcode == op)
674 return op_print_tab[tem].
string;
709 #include "std-operator.def" 729 fprintf_filtered (stream,
"\n\tLanguage %s, %d elements, %ld bytes each.\n",
733 "Hex Value",
"String Value");
734 for (elt = 0; elt < exp->
nelts; elt++)
744 for (eltscan = (
char *) &exp->
elts[elt],
750 isprint (*eltscan) ? (*eltscan & 0xFF) :
'.');
763 static int indent = 0;
769 for (i = 1; i <= indent; i++)
796 struct ui_file *stream,
int elt)
814 case BINOP_LOGICAL_AND:
815 case BINOP_LOGICAL_OR:
816 case BINOP_BITWISE_AND:
817 case BINOP_BITWISE_IOR:
818 case BINOP_BITWISE_XOR:
828 case BINOP_SUBSCRIPT:
833 case BINOP_ASSIGN_MODIFY:
837 case STRUCTOP_MEMBER:
842 case UNOP_LOGICAL_NOT:
843 case UNOP_COMPLEMENT:
846 case UNOP_PREINCREMENT:
847 case UNOP_POSTINCREMENT:
848 case UNOP_PREDECREMENT:
849 case UNOP_POSTDECREMENT:
893 case OP_VAR_MSYM_VALUE:
902 case OP_VAR_ENTRY_VALUE:
934 for (i = 1; i <= nargs + 1; i++)
949 for (i = 1; i <= upper - lower + 1; i++)
953 case UNOP_DYNAMIC_CAST:
954 case UNOP_REINTERPRET_CAST:
956 case UNOP_MEMVAL_TYPE:
990 case STRUCTOP_STRUCT:
1022 case OP_FUNC_STATIC_VAR:
1025 const char *var_name = &exp->
elts[elt + 1].
string;
1033 type_instance_flags
flags 1051 auto print_one = [&] (
const char *mod)
1059 print_one (
"const");
1061 print_one (
"volatile");
1125 case MULTI_SUBSCRIPT:
1126 case OP_F77_UNDETERMINED_ARGLIST:
1145 fputs_filtered (
", after conversion to prefix form:\nExpression: `", stream);
1147 fprintf_filtered (stream,
"'\n\tLanguage %s, %d elements, %ld bytes each.\n",
1152 for (elt = 0; elt < exp->
nelts;)
union exp_element elts[1]
char * hex_string(LONGEST num)
const char * op_name(struct expression *exp, enum exp_opcode opcode)
#define SYMBOL_PRINT_NAME(symbol)
void value_print(struct value *val, struct ui_file *stream, const struct value_print_options *options)
void fputs_unfiltered(const char *buf, struct ui_file *file)
struct value * value_from_contents(struct type *type, const gdb_byte *contents)
char * plongest(LONGEST l)
const struct language_defn * language_defn
void print_floating(const gdb_byte *valaddr, struct type *type, struct ui_file *stream)
void type_print(struct type *type, const char *varstring, struct ui_file *stream, int show)
enum language la_language
void get_no_prettyformat_print_options(struct value_print_options *opts)
#define BYTES_TO_EXP_ELEM(bytes)
const char * la_name_of_this
int longest_to_int(LONGEST)
struct internalvar * internalvar
int dump_subexp(struct expression *exp, struct ui_file *stream, int elt)
#define BLOCK_FUNCTION(bl)
mach_port_t kern_return_t mach_port_t msgports mach_port_t kern_return_t pid_t pid mach_port_t kern_return_t mach_port_t task mach_port_t kern_return_t int flags
enum precedence precedence
#define MSYMBOL_PRINT_NAME(symbol)
const struct block * block
const struct exp_descriptor * la_exp_desc
void dump_raw_expression(struct expression *exp, struct ui_file *stream, const char *note)
const char *(* op_name)(enum exp_opcode)
void dump_prefix_expression(struct expression *exp, struct ui_file *stream)
void fprintf_filtered(struct ui_file *stream, const char *format,...)
void fprintf_unfiltered(struct ui_file *stream, const char *format,...)
void print_expression(struct expression *exp, struct ui_file *stream)
void fputs_filtered(const char *linebuffer, struct ui_file *stream)
char * internalvar_name(const struct internalvar *var)
const char * op_string(enum exp_opcode op)
int dump_subexp_body_standard(struct expression *exp, struct ui_file *stream, int elt)
struct value * value_from_longest(struct type *type, LONGEST num)
struct value * value_at_lazy(struct type *type, CORE_ADDR addr)
#define gdb_print_host_address(ADDR, STREAM)
struct minimal_symbol * msymbol
struct type * builtin_char
const struct language_defn * current_language
void print_longest(struct ui_file *stream, int format, int use_c_format, LONGEST val_long)
void print_subexp_standard(struct expression *exp, int *pos, struct ui_file *stream, enum precedence prec)
void print_subexp(struct expression *exp, int *pos, struct ui_file *stream, enum precedence prec)
int xsnprintf(char *str, size_t size, const char *format,...)
#define TYPE_CODE(thistype)
const struct op_print * la_op_print_tab
void get_user_print_options(struct value_print_options *opts)
int(* dump_subexp_body)(struct expression *, struct ui_file *, int)
const char * op_name_standard(enum exp_opcode opcode)
static int dump_subexp_body(struct expression *exp, struct ui_file *, int)
#define LA_PRINT_STRING(stream, elttype, string, length, encoding, force_ellipses, options)
void(* print_subexp)(struct expression *, int *, struct ui_file *, enum precedence)
const char * type_name_no_tag(const struct type *type)
int target_read_string(CORE_ADDR memaddr, char **string, int len, int *errnop)
void error(const char *fmt,...)