[cfe-commits] [patch] Qualifiers refactor
John McCall
rjmccall at apple.com
Thu Sep 24 12:15:19 PDT 2009
John McCall wrote:
>> @@ -1778,16 +1779,21 @@ QualType Sema::FindCompositePointerType(
>> I = QualifierUnion.begin(),
>> E = QualifierUnion.end();
>> I != E; (void)++I, ++MOC) {
>> + Qualifiers Quals = Qualifiers::fromCVRMask(*I);
>> if (MOC->first && MOC->second) {
>> // Rebuild member pointer type
>> - Composite1 =
>> Context.getMemberPointerType(Composite1.getQualifiedType(*I),
>> - MOC->first);
>> - Composite2 =
>> Context.getMemberPointerType(Composite2.getQualifiedType(*I),
>> - MOC->second);
>> + Composite1 = Context.getMemberPointerType(
>> +
>> Context.getQualifiedType(Composite1, Quals),
>> + MOC->first);
>> + Composite2 = Context.getMemberPointerType(
>> +
>> Context.getQualifiedType(Composite2, Quals),
>> + MOC->second);
>> } else {
>> // Rebuild pointer type
>> - Composite1 =
>> Context.getPointerType(Composite1.getQualifiedType(*I));
>> - Composite2 =
>> Context.getPointerType(Composite2.getQualifiedType(*I));
>> + Composite1
>> + = Context.getPointerType(Context.getQualifiedType(Composite1,
>> Quals));
>> + Composite2
>> + = Context.getPointerType(Context.getQualifiedType(Composite2,
>> Quals));
>> }
>> }
>>
>> Same concern here; we're probably losing non-CVR qualifiers.
>>
>
> Also fixed.
>
I should say, fixed in the "I added a FIXME" sense.
John.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20090924/c7a33389/attachment.html>
More information about the cfe-commits
mailing list