summaryrefslogtreecommitdiff
path: root/include/llvm/Support/RecyclingAllocator.h
diff options
context:
space:
mode:
authorBenjamin Kramer <benny.kra@googlemail.com>2010-04-08 15:22:35 +0000
committerBenjamin Kramer <benny.kra@googlemail.com>2010-04-08 15:22:35 +0000
commit180c3d4edd1219832be8f2cf91f5f73f9757c36f (patch)
treec131587bfa5e192c1a01ae05149a65ba6060965d /include/llvm/Support/RecyclingAllocator.h
parentf042f97d7e6fbaa73a26f494ed642f2e4e2a948d (diff)
downloadllvm-180c3d4edd1219832be8f2cf91f5f73f9757c36f.tar.gz
llvm-180c3d4edd1219832be8f2cf91f5f73f9757c36f.tar.bz2
llvm-180c3d4edd1219832be8f2cf91f5f73f9757c36f.tar.xz
Provide operator delete for BumpPtrAllocator and RecyclingAllocator. They will
never be called but msvc complains that they're missing. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100766 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include/llvm/Support/RecyclingAllocator.h')
-rw-r--r--include/llvm/Support/RecyclingAllocator.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/include/llvm/Support/RecyclingAllocator.h b/include/llvm/Support/RecyclingAllocator.h
index 49f7753718..34ab874778 100644
--- a/include/llvm/Support/RecyclingAllocator.h
+++ b/include/llvm/Support/RecyclingAllocator.h
@@ -63,4 +63,11 @@ inline void *operator new(size_t,
return Allocator.Allocate();
}
+template<class AllocatorType, class T, size_t Size, size_t Align>
+inline void operator delete(void *E,
+ llvm::RecyclingAllocator<AllocatorType,
+ T, Size, Align> &A) {
+ A.Deallocate(E);
+}
+
#endif