diff options
author | gdb-2.5.3 <gdb@fsf.org> | 1988-06-13 01:00:00 +0100 |
---|---|---|
committer | Pedro Alves <palves@redhat.com> | 2012-06-03 15:36:30 +0100 |
commit | 7c75bab3d3ef344a6a0b13b9ab59ecd5855aceb5 (patch) | |
tree | 4e50a84965c0e24ba6734d9717e007e68879c8e0 /gdb/valprint.c | |
parent | 6368691e88d78f0bb6a46b74d7ed86118ac84e8b (diff) | |
download | gdb-7c75bab3d3ef344a6a0b13b9ab59ecd5855aceb5.zip gdb-7c75bab3d3ef344a6a0b13b9ab59ecd5855aceb5.tar.gz gdb-7c75bab3d3ef344a6a0b13b9ab59ecd5855aceb5.tar.bz2 |
gdb-2.5.3
Diffstat (limited to 'gdb/valprint.c')
-rw-r--r-- | gdb/valprint.c | 18 |
1 files changed, 12 insertions, 6 deletions
diff --git a/gdb/valprint.c b/gdb/valprint.c index 32601a6..29df920 100644 --- a/gdb/valprint.c +++ b/gdb/valprint.c @@ -220,7 +220,7 @@ val_print (type, valaddr, address, stream) common: if (i < len) { - fprintf (stream, "& "); + fputc ('&', stream); type_print_varspec_prefix (TYPE_FN_FIELD_TYPE (f, j), stream, 0, 0); fprintf (stream, kind); if (TYPE_FN_FIELD_PHYSNAME (f, j)[0] == '_' @@ -265,7 +265,7 @@ val_print (type, valaddr, address, stream) } if (i < len) { - fprintf (stream, "& "); + fputc ('&', stream); type_print_base (domain, stream, 0, 0); fprintf (stream, "::"); fprintf (stream, "%s", TYPE_FIELD_NAME (domain, i)); @@ -517,7 +517,12 @@ type_print_method_args (args, prefix, varstring, stream) while (1) { type_print (args[i++], "", stream, 0); - if (args[i]->code != TYPE_CODE_VOID) + if (!args[i]) + { + fprintf (stream, " ..."); + break; + } + else if (args[i]->code != TYPE_CODE_VOID) { fprintf (stream, ", "); } @@ -555,7 +560,9 @@ type_print_varspec_prefix (type, stream, show, passed_a_ptr) break; case TYPE_CODE_MEMBER: - type_print_varspec_prefix (TYPE_TARGET_TYPE (type), stream, 0, 0); + type_print_varspec_prefix (TYPE_TARGET_TYPE (type), stream, 0, + passed_a_ptr); + fputc (' ', stream); type_print_base (TYPE_DOMAIN_TYPE (type), stream, 0, passed_a_ptr); fprintf (stream, "::"); @@ -748,8 +755,7 @@ type_print_base (type, stream, show, level) print_spaces (level + 4, stream); if (TYPE_FN_FIELD_VIRTUAL_P (f, j)) fprintf (stream, "virtual "); - type_print_base (TYPE_FN_FIELD_TYPE (f, j), stream, 0, level); - type_print_varspec_prefix (TYPE_FN_FIELD_TYPE (f, j), stream, 0, 0); + type_print (TYPE_TARGET_TYPE (TYPE_TARGET_TYPE (TYPE_FN_FIELD_TYPE (f, j))), "", stream, 0); if (TYPE_FN_FIELD_PHYSNAME (f, j)[0] == '_' && TYPE_FN_FIELD_PHYSNAME (f, j)[1] == '$') type_print_method_args |