diff options
Diffstat (limited to 'gdb')
-rw-r--r-- | gdb/ChangeLog | 5 | ||||
-rw-r--r-- | gdb/expprint.c | 16 |
2 files changed, 19 insertions, 2 deletions
diff --git a/gdb/ChangeLog b/gdb/ChangeLog index 99beeee..fb6e84a 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,3 +1,8 @@ +2006-08-06 Daniel Jacobowitz <dan@codesourcery.com> + + * expprint.c (print_subexp_standard, dump_subexp_body_standard): Add + support for member pointers. + 2006-08-02 Mark Kettenis <kettenis@gnu.org> * arm-tdep.h: Add multiple inclusion protection. diff --git a/gdb/expprint.c b/gdb/expprint.c index 77493b0..c7633b5 100644 --- a/gdb/expprint.c +++ b/gdb/expprint.c @@ -346,6 +346,18 @@ print_subexp_standard (struct expression *exp, int *pos, fputs_filtered (&exp->elts[pc + 2].string, stream); return; + case STRUCTOP_MEMBER: + print_subexp (exp, pos, stream, PREC_SUFFIX); + fputs_filtered (".*", stream); + print_subexp (exp, pos, stream, PREC_SUFFIX); + return; + + case STRUCTOP_MPTR: + print_subexp (exp, pos, stream, PREC_SUFFIX); + fputs_filtered ("->*", stream); + print_subexp (exp, pos, stream, PREC_SUFFIX); + return; + case BINOP_SUBSCRIPT: print_subexp (exp, pos, stream, PREC_SUFFIX); fputs_filtered ("[", stream); @@ -873,6 +885,8 @@ dump_subexp_body_standard (struct expression *exp, case BINOP_IN: case BINOP_RANGE: case BINOP_END: + case STRUCTOP_MEMBER: + case STRUCTOP_MPTR: elt = dump_subexp (exp, stream, elt); case UNOP_NEG: case UNOP_LOGICAL_NOT: @@ -1026,8 +1040,6 @@ dump_subexp_body_standard (struct expression *exp, break; default: case OP_NULL: - case STRUCTOP_MEMBER: - case STRUCTOP_MPTR: case MULTI_SUBSCRIPT: case OP_F77_UNDETERMINED_ARGLIST: case OP_COMPLEX: |