This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: grokdeclarator drops type qualifiers when -aux-info isn't asserted?
On 05/20/09 09:45:11, Joseph S. Myers wrote:
> On Tue, 19 May 2009, Gary Funck wrote:
>
> > That aside, I wonder if it is an error to drop the qualifiers
> > as shown above? In the case of UPC, for example, dropping qualifiers
>
> Please read the code (and comment) immediately above that you quoted,
> which saves the qualifiers combined with those specified in the
> declaration, and the subsequent code applying them in the process of
> building up the type.
> [...] See the named address space patches for
> examples of adding extra type qualifiers.
Thanks. We've generally gotten that part right by adding a few
qualifier bits. We can't however encode UPC's "layout qualifier"
into the qualifier bits and we have to maintain it separately.
I do see now that the layout qualifier on an element type should
be handled earlier along with the rest of the qualifiers in the
section that you're referencing.
> The bug would probably be that it doesn't also drop
> them if flag_gen_aux_info.
Agreed. Though presumably the flag_gen_aux_info logic
will have to be adjusted as well.