------- Comment #9 from rguenth at gcc dot gnu dot org  2007-10-02 16:55 -------
  else if (!cgraph_global_info_ready
           && (TREE_CODE (*tp) == VAR_DECL || TREE_CODE (*tp) ==
FUNCTION_DECL))
    gcc_unreachable ();

the problem is that the C++ FE emits debug info for global using decls from
parsing:

...
#9  0x082a825e in cp_emit_debug_info_for_using (t=0xb7d6705c, context=0x0)
    at /home/richard/src/trunk/gcc/cp/name-lookup.c:5223
---Type <return> to continue, or q <return> to quit---
#10 0x0829f5ef in do_toplevel_using_decl (decl=0xb7d61870, scope=0xb7d61798, 
    name=0xb7d66708) at /home/richard/src/trunk/gcc/cp/name-lookup.c:3360
#11 0x081bca90 in cp_parser_using_declaration (parser=0xb7cd22a4, 
    access_declaration_p=0 '\0')
    at /home/richard/src/trunk/gcc/cp/parser.c:11695
...

via the imported_module_or_decl debug hook.  I guess we should simply queue
these with the varpool.  Or probably invent a new pool for just this use.
Or just weaken the sanity check.


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=31899

Reply via email to