/* Support for printing C++ values for GDB, the GNU debugger.
- Copyright (C) 1986-2018 Free Software Foundation, Inc.
+ Copyright (C) 1986-2019 Free Software Foundation, Inc.
This file is part of GDB.
#include "language.h"
#include "extension.h"
#include "typeprint.h"
-#include "byte-vector.h"
+#include "common/byte-vector.h"
/* Controls printing of vtbl's. */
static void
continue;
if (fields_seen)
- fprintf_filtered (stream, ", ");
+ {
+ fputs_filtered (",", stream);
+ if (!options->prettyformat)
+ fputs_filtered (" ", stream);
+ }
else if (n_baseclasses > 0)
{
if (options->prettyformat)
print_spaces_filtered (2 + 2 * recurse, stream);
fputs_filtered ("members of ", stream);
fputs_filtered (TYPE_NAME (type), stream);
- fputs_filtered (": ", stream);
+ fputs_filtered (":", stream);
}
}
fields_seen = 1;
{
struct value *v = NULL;
- TRY
+ try
{
v = value_static_field (type, i);
}
- CATCH (ex, RETURN_MASK_ERROR)
+ catch (const gdb_exception_error &ex)
{
fprintf_filtered (stream,
_("<error reading variable: %s>"),
- ex.message);
+ ex.what ());
}
- END_CATCH
cp_print_static_field (TYPE_FIELD_TYPE (type, i),
v, stream, recurse + 1,
if (last_set_recurse != recurse)
{
- size_t obstack_final_size =
+ obstack_final_size =
obstack_object_size (&dont_print_stat_array_obstack);
if (obstack_final_size > stat_array_obstack_initial_size)
thisoffset = offset;
thistype = real_type;
- TRY
+ try
{
boffset = baseclass_offset (type, i, valaddr, offset, address, val);
}
- CATCH (ex, RETURN_MASK_ERROR)
+ catch (const gdb_exception_error &ex)
{
if (ex.error == NOT_AVAILABLE_ERROR)
skip = -1;
else
skip = 1;
}
- END_CATCH
if (skip == 0)
{