@@ -244,9 +244,9 @@ class NameMatcher: public ASTWalker {
244
244
std::vector<ResolvedLoc> ResolvedLocs;
245
245
ArrayRef<Token> TokensToCheck;
246
246
247
- // / The \c Expr argument of a parent \c CustomAttr (if one exists) and
247
+ // / The \c ArgumentList of a parent \c CustomAttr (if one exists) and
248
248
// / the \c SourceLoc of the type name it applies to.
249
- llvm::Optional<Located<Expr *>> CustomAttrArg ;
249
+ llvm::Optional<Located<ArgumentList *>> CustomAttrArgList ;
250
250
unsigned InactiveConfigRegionNestings = 0 ;
251
251
unsigned SelectorNestings = 0 ;
252
252
@@ -265,12 +265,13 @@ class NameMatcher: public ASTWalker {
265
265
bool shouldSkip (SourceRange Range);
266
266
bool shouldSkip (CharSourceRange Range);
267
267
bool tryResolve (ASTWalker::ParentTy Node, SourceLoc NameLoc);
268
- bool tryResolve (ASTWalker::ParentTy Node, DeclNameLoc NameLoc, Expr *Arg);
268
+ bool tryResolve (ASTWalker::ParentTy Node, DeclNameLoc NameLoc,
269
+ ArgumentList *Args);
269
270
bool tryResolve (ASTWalker::ParentTy Node, SourceLoc NameLoc, LabelRangeType RangeType,
270
271
ArrayRef<CharSourceRange> LabelLocs,
271
272
Optional<unsigned > FirstTrailingLabel);
272
273
bool handleCustomAttrs (Decl *D);
273
- Expr * getApplicableArgFor (Expr* E);
274
+ ArgumentList * getApplicableArgsFor (Expr* E);
274
275
275
276
std::pair<bool , Expr*> walkToExprPre (Expr *E) override ;
276
277
Expr* walkToExprPost (Expr *E) override ;
@@ -283,6 +284,9 @@ class NameMatcher: public ASTWalker {
283
284
std::pair<bool , Pattern*> walkToPatternPre (Pattern *P) override ;
284
285
bool shouldWalkIntoGenericParams () override { return true ; }
285
286
287
+ std::pair<bool , ArgumentList *>
288
+ walkToArgumentListPre (ArgumentList *ArgList) override ;
289
+
286
290
// FIXME: Remove this
287
291
bool shouldWalkAccessorsTheOldWay () override { return true ; }
288
292
@@ -568,13 +572,14 @@ struct CallArgInfo {
568
572
};
569
573
570
574
std::vector<CallArgInfo>
571
- getCallArgInfo (SourceManager &SM, Expr *Arg , LabelRangeEndAt EndKind);
575
+ getCallArgInfo (SourceManager &SM, ArgumentList *Args , LabelRangeEndAt EndKind);
572
576
573
577
// Get the ranges of argument labels from an Arg, either tuple or paren, and
574
578
// the index of the first trailing closure argument, if any. This includes empty
575
579
// ranges for any unlabelled arguments, including the first trailing closure.
576
580
std::pair<std::vector<CharSourceRange>, Optional<unsigned >>
577
- getCallArgLabelRanges (SourceManager &SM, Expr *Arg, LabelRangeEndAt EndKind);
581
+ getCallArgLabelRanges (SourceManager &SM, ArgumentList *Args,
582
+ LabelRangeEndAt EndKind);
578
583
579
584
// / Whether a decl is defined from clang source.
580
585
bool isFromClang (const Decl *D);
0 commit comments