summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--llvm/include/llvm/Support/Allocator.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/llvm/include/llvm/Support/Allocator.h b/llvm/include/llvm/Support/Allocator.h
index d259415bc39..275086bffdf 100644
--- a/llvm/include/llvm/Support/Allocator.h
+++ b/llvm/include/llvm/Support/Allocator.h
@@ -211,7 +211,7 @@ public:
typename enable_if<isPodLike<T>, ArrayRef<T> >::type
allocateCopy(ArrayRef<T> Src) {
size_t Length = Src.size();
- T *P = allocateCopy(Src.data(), Length*sizeof(T));
+ T *P = allocateCopy<T>(Src.data(), Length);
return makeArrayRef(P, Length);
}
OpenPOWER on IntegriCloud