Tue Apr 30 13:13:33 1991 Michael Tiemann (tiemann at cygint.cygnus.com)

* valprint.c (type_print_base): If the type being printed is a
	struct containing undefined types, print "<undefine type>"
	as the type instead of crashing.
	* values.c (value_headof): Get the vtable pointer taking
	TYPE_VPTR_BASETYPE into account.
	* symtab.c, symtab.h, dbxread.c: Fix various whitespace splotches.
This commit is contained in:
Michael Tiemann
1991-04-30 20:19:02 +00:00
parent 98c1b9e79b
commit aec4cb918e
6 changed files with 31 additions and 10 deletions

View File

@@ -301,7 +301,7 @@ value_print (val, stream, format, pretty)
printf_filtered ("<value optimized out>");
return 0;
}
/* A "repeated" value really contains several values in a row.
They are made by the @ operator.
Print such values as if they were arrays. */
@@ -1640,7 +1640,15 @@ type_print_base (type, stream, show, level)
fprintf_filtered (stream, "virtual ");
else if (TYPE_FN_FIELD_STATIC_P (f, j))
fprintf_filtered (stream, "static ");
type_print (TYPE_TARGET_TYPE (TYPE_FN_FIELD_TYPE (f, j)), "", stream, 0);
if (TYPE_TARGET_TYPE (TYPE_FN_FIELD_TYPE (f, j)) == 0)
{
/* Keep GDB from crashing here. */
fprintf (stream, "<undefined type> %s;\n",
TYPE_FN_FIELD_PHYSNAME (f, j));
break;
}
else
type_print (TYPE_TARGET_TYPE (TYPE_FN_FIELD_TYPE (f, j)), "", stream, 0);
if (TYPE_FLAGS (TYPE_FN_FIELD_TYPE (f, j)) & TYPE_FLAG_STUB)
{
/* Build something we can demangle. */