diff options
author | Ahmed Charles <ace2001ac@gmail.com> | 2012-02-25 11:00:22 +0000 |
---|---|---|
committer | Ahmed Charles <ace2001ac@gmail.com> | 2012-02-25 11:00:22 +0000 |
commit | 13a140caba448a66ffcc5ff0d32a87d6e4f4ad3f (patch) | |
tree | 4c9eabc3b789a4864cc8c84242255694e597e17a /lib/Sema/SemaExpr.cpp | |
parent | 5297d71e8c85f9b04dc31c690e91c6a2f7eddb90 (diff) |
ArrayRef'ize various functions in the AST/Parser/Sema.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@151447 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Sema/SemaExpr.cpp')
-rw-r--r-- | lib/Sema/SemaExpr.cpp | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/lib/Sema/SemaExpr.cpp b/lib/Sema/SemaExpr.cpp index 987ce55c2a..5d6f5ef7f4 100644 --- a/lib/Sema/SemaExpr.cpp +++ b/lib/Sema/SemaExpr.cpp @@ -1257,7 +1257,7 @@ Sema::DecomposeUnqualifiedId(const UnqualifiedId &Id, bool Sema::DiagnoseEmptyLookup(Scope *S, CXXScopeSpec &SS, LookupResult &R, CorrectionCandidateCallback &CCC, TemplateArgumentListInfo *ExplicitTemplateArgs, - Expr **Args, unsigned NumArgs) { + llvm::ArrayRef<Expr *> Args) { DeclarationName Name = R.getLookupName(); unsigned diagnostic = diag::err_undeclared_var_use; @@ -1387,11 +1387,11 @@ bool Sema::DiagnoseEmptyLookup(Scope *S, CXXScopeSpec &SS, LookupResult &R, dyn_cast<FunctionTemplateDecl>(*CD)) AddTemplateOverloadCandidate( FTD, DeclAccessPair::make(FTD, AS_none), ExplicitTemplateArgs, - Args, NumArgs, OCS); + Args, OCS); else if (FunctionDecl *FD = dyn_cast<FunctionDecl>(*CD)) if (!ExplicitTemplateArgs || ExplicitTemplateArgs->size() == 0) AddOverloadCandidate(FD, DeclAccessPair::make(FD, AS_none), - Args, NumArgs, OCS); + Args, OCS); } switch (OCS.BestViableFunction(*this, R.getNameLoc(), Best)) { case OR_Success: @@ -3450,7 +3450,8 @@ Sema::ActOnCallExpr(Scope *S, Expr *Fn, SourceLocation LParenLoc, bool Dependent = false; if (Fn->isTypeDependent()) Dependent = true; - else if (Expr::hasAnyTypeDependentArguments(Args, NumArgs)) + else if (Expr::hasAnyTypeDependentArguments( + llvm::makeArrayRef(Args, NumArgs))) Dependent = true; if (Dependent) { |