|
@@ -3826,8 +3826,7 @@ Sema::TemplateDeductionResult Sema::DeduceTemplateArguments(
|
|
if (Args.size() < Function->getMinRequiredArguments() && !PartialOverloading)
|
|
if (Args.size() < Function->getMinRequiredArguments() && !PartialOverloading)
|
|
return TDK_TooFewArguments;
|
|
return TDK_TooFewArguments;
|
|
else if (TooManyArguments(NumParams, Args.size(), PartialOverloading)) {
|
|
else if (TooManyArguments(NumParams, Args.size(), PartialOverloading)) {
|
|
- const FunctionProtoType *Proto
|
|
|
|
- = Function->getType()->getAs<FunctionProtoType>();
|
|
|
|
|
|
+ const auto *Proto = Function->getType()->castAs<FunctionProtoType>();
|
|
if (Proto->isTemplateVariadic())
|
|
if (Proto->isTemplateVariadic())
|
|
/* Do nothing */;
|
|
/* Do nothing */;
|
|
else if (!Proto->isVariadic())
|
|
else if (!Proto->isVariadic())
|
|
@@ -3965,11 +3964,8 @@ QualType Sema::adjustCCAndNoReturn(QualType ArgFunctionType,
|
|
if (ArgFunctionType.isNull())
|
|
if (ArgFunctionType.isNull())
|
|
return ArgFunctionType;
|
|
return ArgFunctionType;
|
|
|
|
|
|
- const FunctionProtoType *FunctionTypeP =
|
|
|
|
- FunctionType->castAs<FunctionProtoType>();
|
|
|
|
- const FunctionProtoType *ArgFunctionTypeP =
|
|
|
|
- ArgFunctionType->getAs<FunctionProtoType>();
|
|
|
|
-
|
|
|
|
|
|
+ const auto *FunctionTypeP = FunctionType->castAs<FunctionProtoType>();
|
|
|
|
+ const auto *ArgFunctionTypeP = ArgFunctionType->castAs<FunctionProtoType>();
|
|
FunctionProtoType::ExtProtoInfo EPI = ArgFunctionTypeP->getExtProtoInfo();
|
|
FunctionProtoType::ExtProtoInfo EPI = ArgFunctionTypeP->getExtProtoInfo();
|
|
bool Rebuild = false;
|
|
bool Rebuild = false;
|
|
|
|
|