diff options
author | John Criswell <criswell@uiuc.edu> | 2004-10-28 17:31:46 +0000 |
---|---|---|
committer | John Criswell <criswell@uiuc.edu> | 2004-10-28 17:31:46 +0000 |
commit | cd74271a790294198cdc101e3c08e5b063765220 (patch) | |
tree | d839c41bdcc165a5104ff887b20b1d300c2ab9f0 /include/llvm | |
parent | cd1e7dddd001a108994a0c31252762b44c24d821 (diff) | |
download | external_llvm-cd74271a790294198cdc101e3c08e5b063765220.zip external_llvm-cd74271a790294198cdc101e3c08e5b063765220.tar.gz external_llvm-cd74271a790294198cdc101e3c08e5b063765220.tar.bz2 |
Only add the _Alloc_traits specialization in if we're compiling for
Linux and not compiling for Sparc.
This is still probably not correct, or portable, but it'll do for now.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@17321 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include/llvm')
-rw-r--r-- | include/llvm/Support/MallocAllocator.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/include/llvm/Support/MallocAllocator.h b/include/llvm/Support/MallocAllocator.h index c17517e..18ec611 100644 --- a/include/llvm/Support/MallocAllocator.h +++ b/include/llvm/Support/MallocAllocator.h @@ -72,6 +72,7 @@ inline bool operator!=(const MallocAllocator<T>&, const MallocAllocator<T>&) { } } // End llvm namespace +#if defined(__linux__) && !(defined (sparc) || defined (_sparc)) namespace std { template<typename Type, typename Type2> struct _Alloc_traits<Type, ::llvm::MallocAllocator<Type2> > { @@ -81,5 +82,6 @@ namespace std { typedef ::llvm::MallocAllocator<Type> allocator_type; }; } +#endif #endif |