@@ -1571,8 +1571,7 @@ FunctionTemplate* Parser::WalkFunctionTemplate(const clang::FunctionTemplateDecl
1571
1571
if (auto MD = dyn_cast<CXXMethodDecl>(TemplatedDecl))
1572
1572
Function = WalkMethodCXX (MD);
1573
1573
else
1574
- Function = WalkFunction (TemplatedDecl, /* IsDependent=*/ true ,
1575
- /* AddToNamespace=*/ false );
1574
+ Function = WalkFunction (TemplatedDecl, /* AddToNamespace=*/ false );
1576
1575
1577
1576
FT = new FunctionTemplate ();
1578
1577
HandleDeclaration (TD, FT);
@@ -3157,12 +3156,11 @@ void Parser::MarkValidity(Function* F)
3157
3156
c->getSema ().getDiagnostics ().setClient (existingClient, false );
3158
3157
}
3159
3158
3160
- void Parser::WalkFunction (const clang::FunctionDecl* FD, Function* F,
3161
- bool IsDependent)
3159
+ void Parser::WalkFunction (const clang::FunctionDecl* FD, Function* F)
3162
3160
{
3163
3161
using namespace clang ;
3164
3162
3165
- assert (FD->getBuiltinID () == 0 );
3163
+ assert (FD->getBuiltinID () == 0 );
3166
3164
auto FT = FD->getType ()->getAs <clang::FunctionType>();
3167
3165
3168
3166
auto NS = GetNamespace (FD);
@@ -3206,7 +3204,7 @@ void Parser::WalkFunction(const clang::FunctionDecl* FD, Function* F,
3206
3204
HandlePreprocessedEntities (F, FTL.getParensRange (), MacroLocation::FunctionParameters);
3207
3205
}
3208
3206
}
3209
-
3207
+
3210
3208
auto ReturnType = FD->getReturnType ();
3211
3209
if (FD->isExternallyVisible ())
3212
3210
CompleteIfSpecializationType (ReturnType);
@@ -3232,7 +3230,7 @@ void Parser::WalkFunction(const clang::FunctionDecl* FD, Function* F,
3232
3230
if (FTL)
3233
3231
{
3234
3232
auto FTInfo = FTL.castAs <FunctionTypeLoc>();
3235
- assert (!FTInfo.isNull ());
3233
+ assert (!FTInfo.isNull ());
3236
3234
3237
3235
ParamStartLoc = FTInfo.getLParenLoc ();
3238
3236
ResultLoc = FTInfo.getReturnLoc ().getBeginLoc ();
@@ -3283,7 +3281,7 @@ void Parser::WalkFunction(const clang::FunctionDecl* FD, Function* F,
3283
3281
const CXXMethodDecl* MD;
3284
3282
if (FD->isDependentContext () ||
3285
3283
((MD = dyn_cast<CXXMethodDecl>(FD)) && !MD->isStatic () &&
3286
- !HasLayout (cast<CXXRecordDecl>(MD->getDeclContext ()))) ||
3284
+ !HasLayout (cast<CXXRecordDecl>(MD->getDeclContext ()))) ||
3287
3285
!CanCheckCodeGenInfo (c->getSema (), FD->getReturnType ().getTypePtr ()) ||
3288
3286
std::any_of (FD->parameters ().begin (), FD->parameters ().end (),
3289
3287
[this ](auto * P) { return !CanCheckCodeGenInfo (c->getSema (), P->getType ().getTypePtr ()); }))
@@ -3307,8 +3305,7 @@ void Parser::WalkFunction(const clang::FunctionDecl* FD, Function* F,
3307
3305
F->qualifiedType = GetQualifiedType (FD->getType (), &FTL);
3308
3306
}
3309
3307
3310
- Function* Parser::WalkFunction (const clang::FunctionDecl* FD, bool IsDependent,
3311
- bool AddToNamespace)
3308
+ Function* Parser::WalkFunction (const clang::FunctionDecl* FD, bool AddToNamespace)
3312
3309
{
3313
3310
using namespace clang ;
3314
3311
@@ -3328,7 +3325,7 @@ Function* Parser::WalkFunction(const clang::FunctionDecl* FD, bool IsDependent,
3328
3325
if (AddToNamespace)
3329
3326
NS->Functions .push_back (F);
3330
3327
3331
- WalkFunction (FD, F, IsDependent );
3328
+ WalkFunction (FD, F);
3332
3329
3333
3330
return F;
3334
3331
}
0 commit comments