diff options
author | Craig Topper <craig.topper@gmail.com> | 2014-08-30 16:55:39 +0000 |
---|---|---|
committer | Craig Topper <craig.topper@gmail.com> | 2014-08-30 16:55:39 +0000 |
commit | d39a2d406398ae7625b36eb0f5aff00d22808cc1 (patch) | |
tree | 7fb0fccf418db8882e81cde243d246fc20b8b1a0 /lib/Sema/SemaChecking.cpp | |
parent | 62c112277e6b405f06a24bc505ce3c084e20a2b3 (diff) |
Use llvm::makeArrayRef instead of explicitly calling ArrayRef constructor and mentioning the type. This works now that we have a conversion from ArrayRef<T*> to ArrayRef<const T*>.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@216824 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Sema/SemaChecking.cpp')
-rw-r--r-- | lib/Sema/SemaChecking.cpp | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/lib/Sema/SemaChecking.cpp b/lib/Sema/SemaChecking.cpp index c1263d45eb..87042d1c07 100644 --- a/lib/Sema/SemaChecking.cpp +++ b/lib/Sema/SemaChecking.cpp @@ -883,7 +883,7 @@ bool Sema::CheckFunctionCall(FunctionDecl *FDecl, CallExpr *TheCall, ++Args; --NumArgs; } - checkCall(FDecl, llvm::makeArrayRef<const Expr *>(Args, NumArgs), NumParams, + checkCall(FDecl, llvm::makeArrayRef(Args, NumArgs), NumParams, IsMemberFunction, TheCall->getRParenLoc(), TheCall->getCallee()->getSourceRange(), CallType); @@ -942,8 +942,8 @@ bool Sema::CheckPointerCall(NamedDecl *NDecl, CallExpr *TheCall, } unsigned NumParams = Proto ? Proto->getNumParams() : 0; - checkCall(NDecl, llvm::makeArrayRef<const Expr *>(TheCall->getArgs(), - TheCall->getNumArgs()), + checkCall(NDecl, llvm::makeArrayRef(TheCall->getArgs(), + TheCall->getNumArgs()), NumParams, /*IsMemberFunction=*/false, TheCall->getRParenLoc(), TheCall->getCallee()->getSourceRange(), CallType); @@ -958,8 +958,7 @@ bool Sema::CheckOtherCall(CallExpr *TheCall, const FunctionProtoType *Proto) { unsigned NumParams = Proto ? Proto->getNumParams() : 0; checkCall(/*FDecl=*/nullptr, - llvm::makeArrayRef<const Expr *>(TheCall->getArgs(), - TheCall->getNumArgs()), + llvm::makeArrayRef(TheCall->getArgs(), TheCall->getNumArgs()), NumParams, /*IsMemberFunction=*/false, TheCall->getRParenLoc(), TheCall->getCallee()->getSourceRange(), CallType); |