diff options
author | Devang Patel <dpatel@apple.com> | 2005-07-22 18:55:53 +0000 |
---|---|---|
committer | Devang Patel <dpatel@apple.com> | 2005-07-22 18:55:53 +0000 |
commit | 27d0a692a8650909d0c180d3449626531c9f466f (patch) | |
tree | 092e46ffa5172046a25b3eed8137b1cc44bb94f3 /gcc/cp/decl.c | |
parent | a7a778926be5ba271f9d0350fdeecb7dd733fc2e (diff) |
Radar 4182972
* name-lookup.c (pushtag): Update comment.
* decl.c (grokdeclarator): Generate debug info for anonymous aggregate
type when it receives real name.
git-svn-id: https://gcc.gnu.org/svn/gcc/branches/apple-local-200502-branch@102291 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/cp/decl.c')
-rw-r--r-- | gcc/cp/decl.c | 14 |
1 files changed, 13 insertions, 1 deletions
diff --git a/gcc/cp/decl.c b/gcc/cp/decl.c index a6e6989c8a7..014540f02b4 100644 --- a/gcc/cp/decl.c +++ b/gcc/cp/decl.c @@ -7706,7 +7706,19 @@ grokdeclarator (const cp_declarator *declarator, /* Replace the anonymous name with the real name everywhere. */ for (t = TYPE_MAIN_VARIANT (type); t; t = TYPE_NEXT_VARIANT (t)) if (TYPE_NAME (t) == oldname) - TYPE_NAME (t) = decl; + /* APPLE LOCAL begin 4182972 */ + { + TYPE_NAME (t) = decl; + + /* Debug info was not generated earlier for anonymous aggregates. + Now is the time generate debug info for such types. */ + if (ANON_AGGRNAME_P (DECL_NAME(oldname))) + { + DECL_IGNORED_P (TYPE_STUB_DECL (t)) = 0; + debug_hooks->type_decl (TYPE_STUB_DECL (t), LOCAL_CLASS_P (t)); + } + } + /* APPLE LOCAL end 4182972 */ if (TYPE_LANG_SPECIFIC (type)) TYPE_WAS_ANONYMOUS (type) = 1; |