* gdbtypes.c (fill_in_vptr_fieldno): Call check_stub_type.
* gdbtypes.{c,h}: Improve comments on vptr_fieldno.
This commit is contained in:
parent
19d06401a4
commit
ac88287fa2
3 changed files with 21 additions and 4 deletions
|
@ -1,3 +1,8 @@
|
||||||
|
Mon Aug 2 12:06:00 1993 Jim Kingdon (kingdon@lioth.cygnus.com)
|
||||||
|
|
||||||
|
* gdbtypes.c (fill_in_vptr_fieldno): Call check_stub_type.
|
||||||
|
* gdbtypes.{c,h}: Improve comments on vptr_fieldno.
|
||||||
|
|
||||||
Mon Aug 2 11:58:52 1993 Fred Fish (fnf@deneb.cygnus.com)
|
Mon Aug 2 11:58:52 1993 Fred Fish (fnf@deneb.cygnus.com)
|
||||||
|
|
||||||
* README: Elaborate on gdb C++ support and cfront support.
|
* README: Elaborate on gdb C++ support and cfront support.
|
||||||
|
|
|
@ -749,13 +749,19 @@ lookup_struct_elt_type (type, name, noerr)
|
||||||
return (struct type *)-1; /* For lint */
|
return (struct type *)-1; /* For lint */
|
||||||
}
|
}
|
||||||
|
|
||||||
/* This function is really horrible, but to avoid it, there would need
|
/* If possible, make the vptr_fieldno and vptr_basetype fields of TYPE
|
||||||
to be more filling in of forward references. */
|
valid. Callers should be aware that in some cases (for example,
|
||||||
|
the type or one of its baseclasses is a stub type and we are
|
||||||
|
debugging a .o file), this function will not be able to find the virtual
|
||||||
|
function table pointer, and vptr_fieldno will remain -1 and vptr_basetype
|
||||||
|
will remain NULL. */
|
||||||
|
|
||||||
void
|
void
|
||||||
fill_in_vptr_fieldno (type)
|
fill_in_vptr_fieldno (type)
|
||||||
struct type *type;
|
struct type *type;
|
||||||
{
|
{
|
||||||
|
check_stub_type (type);
|
||||||
|
|
||||||
if (TYPE_VPTR_FIELDNO (type) < 0)
|
if (TYPE_VPTR_FIELDNO (type) < 0)
|
||||||
{
|
{
|
||||||
int i;
|
int i;
|
||||||
|
|
|
@ -255,8 +255,7 @@ struct type
|
||||||
} *fields;
|
} *fields;
|
||||||
|
|
||||||
/* For types with virtual functions, VPTR_BASETYPE is the base class which
|
/* For types with virtual functions, VPTR_BASETYPE is the base class which
|
||||||
defined the virtual function table pointer. VPTR_FIELDNO is
|
defined the virtual function table pointer.
|
||||||
the field number of that pointer in the structure.
|
|
||||||
|
|
||||||
For types that are pointer to member types, VPTR_BASETYPE
|
For types that are pointer to member types, VPTR_BASETYPE
|
||||||
is the type that this pointer is a member of.
|
is the type that this pointer is a member of.
|
||||||
|
@ -265,6 +264,13 @@ struct type
|
||||||
|
|
||||||
struct type *vptr_basetype;
|
struct type *vptr_basetype;
|
||||||
|
|
||||||
|
/* Field number of the virtual function table pointer in
|
||||||
|
VPTR_BASETYPE. If -1, we were unable to find the virtual
|
||||||
|
function table pointer in initial symbol reading, and
|
||||||
|
fill_in_vptr_fieldno should be called to find it if possible.
|
||||||
|
|
||||||
|
Unused if this type does not have virtual functions. */
|
||||||
|
|
||||||
int vptr_fieldno;
|
int vptr_fieldno;
|
||||||
|
|
||||||
/* Slot to point to additional language-specific fields of this type. */
|
/* Slot to point to additional language-specific fields of this type. */
|
||||||
|
|
Loading…
Add table
Reference in a new issue