This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c/47939] Missing DW_TAG_typedef for qualified types
- From: "rguenth at gcc dot gnu.org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Tue, 1 Mar 2011 15:42:18 +0000
- Subject: [Bug c/47939] Missing DW_TAG_typedef for qualified types
- Auto-submitted: auto-generated
- References: <bug-47939-4@http.gcc.gnu.org/bugzilla/>
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=47939
--- Comment #5 from Richard Guenther <rguenth at gcc dot gnu.org> 2011-03-01 15:41:53 UTC ---
The patch bootstrapped and tested ok. Removing
if (!flag_gen_aux_info && (TYPE_QUALS (element_type)))
type = TYPE_MAIN_VARIANT (type);
unconditionally breaks gcc.dg/array-quals-2.c (but nothing else).
Whether that is a bug or such radical fix is wrong remains to be determined.
Changing types based on flag_gen_aux_info definitely looks wrong.
Probably a better general approach would be to make c_build_qualified_type
also take a desired name as argument instead of using TYPE_NAME.