diff options
author | Anders Carlsson <andersca@mac.com> | 2009-05-31 19:49:47 +0000 |
---|---|---|
committer | Anders Carlsson <andersca@mac.com> | 2009-05-31 19:49:47 +0000 |
commit | fc27d268cb34cbb8d186c6ad7cc043d41581ce71 (patch) | |
tree | 03f1e2a0a6ff5d78f9578156ad1991a43b4cd336 /lib/Sema/SemaExprCXX.cpp | |
parent | 8662587fa75d3fb04f873e265841c9314c7f5523 (diff) |
Fix an off by one error when trying to perform copy initialization of operator new and operator delete arguments. Sebastian, please review.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@72670 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Sema/SemaExprCXX.cpp')
-rw-r--r-- | lib/Sema/SemaExprCXX.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/Sema/SemaExprCXX.cpp b/lib/Sema/SemaExprCXX.cpp index 73cc0513f0..a44dcf6f8b 100644 --- a/lib/Sema/SemaExprCXX.cpp +++ b/lib/Sema/SemaExprCXX.cpp @@ -550,7 +550,7 @@ bool Sema::FindAllocationOverload(SourceLocation StartLoc, SourceRange Range, // asserted on, though, since invalid decls are left in there.) for (unsigned i = 1; i < NumArgs; ++i) { // FIXME: Passing word to diagnostic. - if (PerformCopyInitialization(Args[i-1], + if (PerformCopyInitialization(Args[i], FnDecl->getParamDecl(i)->getType(), "passing")) return true; |