[PATCH] Canonical types (1/3)

Paolo Carlini pcarlini@suse.de
Tue Dec 5 16:07:00 GMT 2006


Hi Doug, everyone,

>> > >        TYPE_ALIGN (type) = boundary;
>> > > +      TYPE_CANONICAL (type) = TYPE_CANONICAL (orig_type);
>> >
>> > Eek.  So, despite having different alignments, we consider these types
>> > "the same"?  If that's what we already do, then it's OK to preserve 
>> that
>> > behavior, but it sure seems worrisome.
>>
>> I'm concerned about that as well.  I think we need a more precise 
>> definition
>> someplace of what is allowed to differ between two "variants" of a type.
>
> > > +      type = build_variant_type_copy (orig_type);
>
> I've been following whatever "comptypes" does, because that's the
> behavior canonical types need to mimic to provide the same behavior
> that we have now.

At the risk of being of topic, and vague, I'd like to remind Doug and 
all the interested people that, talking about C++0x, we have the open 
issue C++/19163, which, among other things, blocks a general, fully 
conforming, implementation of the alignment traits. If someone, among 
the knowledgeable people, can start giving some thought to the issue it 
would be great (*)...

Paolo.

(*) Myself, while we are speaking, I'm trying to make progress on the 
other parts of the front-end support to type traits task (C++/26099).



More information about the Gcc-patches mailing list