> Yes, the calling convention can always change at decl merging time due to > static methods or declarations with explicit conventions. Templates make > that redeclaration lookup complicated.
Yes, this is pretty horrible :-(
> Use castAs<> if you're going to dereference unconditionally.
Done.
> + if (ArgFunctionTypeP->getCallConv() != CC) {
> + FunctionType::ExtInfo EI =
> + ArgFunctionTypeP->getExtInfo().withCallingConv(CC);
> + ArgFunctionTypeP = cast<FunctionProtoType>(
> + Context.adjustFunctionType(ArgFunctionTypeP, EI));
> + ArgFunctionType = QualType(ArgFunctionTypeP, 0);
> + }
> + }
>
> This looks like the logic I added to
> Sema::CheckFunctionTemplateSpecialization() in r190377. If you add this,
> can we remove it? If not, can we share it? See also the related ExactlyInt
> test case.
Yes, looks like we can also handle noreturn in here. An updated patch
is attached.
Cheers,
Rafale
t.patch
Description: Binary data
_______________________________________________ cfe-commits mailing list [email protected] http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits
