[Bug c++/78235] [7 Regression] libstdc++ testsuite run.cc ICE in int_bit_position
dje at gcc dot gnu.org
gcc-bugzilla@gcc.gnu.org
Thu Dec 1 15:58:00 GMT 2016
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78235
--- Comment #5 from David Edelsohn <dje at gcc dot gnu.org> ---
This fails in dbxout.c:dbxout_type_fields()
/* Output the name, type, position (in bits), size (in bits) of each
field that we can support. */
for (tem = TYPE_FIELDS (type); tem; tem = DECL_CHAIN (tem))
...
if (VAR_P (tem))
{
...
}
else
{
stabstr_C (',');
stabstr_D (int_bit_position (tem));
stabstr_C (',');
stabstr_D (tree_to_uhwi (DECL_SIZE (tem)));
stabstr_C (';');
}
tem is a TEMPLATE_DECL. It is occuring under the case for RECORD_TYPE,
UNION_TYPE and QUAL_UNION_TYPE.
Another part of dbxout.c states
/* Skip methods that aren't FUNCTION_DECLs. (In C++, these
include TEMPLATE_DECLs.) The debugger doesn't know what
to do with such entities anyhow. */
so I'm tempted to fix this by ignoring TEMPLATE_DECLs for in this logic as
well.
More information about the Gcc-bugs
mailing list