diff options
-rw-r--r-- | libcxx/include/new | 2 | ||||
-rw-r--r-- | libcxx/src/new.cpp | 16 |
2 files changed, 8 insertions, 10 deletions
diff --git a/libcxx/include/new b/libcxx/include/new index d1248562ffb..31bb5982eed 100644 --- a/libcxx/include/new +++ b/libcxx/include/new @@ -138,8 +138,6 @@ _LIBCPP_NEW_DELETE_VIS void* operator new[](std::size_t __sz, const std::nothrow _LIBCPP_NEW_DELETE_VIS void operator delete[](void* __p) _NOEXCEPT; _LIBCPP_NEW_DELETE_VIS void operator delete[](void* __p, const std::nothrow_t&) _NOEXCEPT; -#undef _LIBCPP_NEW_DELETE_VIS - inline _LIBCPP_INLINE_VISIBILITY void* operator new (std::size_t, void* __p) _NOEXCEPT {return __p;} inline _LIBCPP_INLINE_VISIBILITY void* operator new[](std::size_t, void* __p) _NOEXCEPT {return __p;} inline _LIBCPP_INLINE_VISIBILITY void operator delete (void*, void*) _NOEXCEPT {} diff --git a/libcxx/src/new.cpp b/libcxx/src/new.cpp index a1001816156..961c02086d8 100644 --- a/libcxx/src/new.cpp +++ b/libcxx/src/new.cpp @@ -39,7 +39,7 @@ // in this shared library, so that they can be overriden by programs // that define non-weak copies of the functions. -_LIBCPP_WEAK _LIBCPP_FUNC_VIS +_LIBCPP_WEAK _LIBCPP_NEW_DELETE_VIS void * operator new(std::size_t size) #if !__has_feature(cxx_noexcept) @@ -66,7 +66,7 @@ operator new(std::size_t size) return p; } -_LIBCPP_WEAK _LIBCPP_FUNC_VIS +_LIBCPP_WEAK _LIBCPP_NEW_DELETE_VIS void* operator new(size_t size, const std::nothrow_t&) _NOEXCEPT { @@ -85,7 +85,7 @@ operator new(size_t size, const std::nothrow_t&) _NOEXCEPT return p; } -_LIBCPP_WEAK _LIBCPP_FUNC_VIS +_LIBCPP_WEAK _LIBCPP_NEW_DELETE_VIS void* operator new[](size_t size) #if !__has_feature(cxx_noexcept) @@ -95,7 +95,7 @@ operator new[](size_t size) return ::operator new(size); } -_LIBCPP_WEAK _LIBCPP_FUNC_VIS +_LIBCPP_WEAK _LIBCPP_NEW_DELETE_VIS void* operator new[](size_t size, const std::nothrow_t&) _NOEXCEPT { @@ -114,7 +114,7 @@ operator new[](size_t size, const std::nothrow_t&) _NOEXCEPT return p; } -_LIBCPP_WEAK _LIBCPP_FUNC_VIS +_LIBCPP_WEAK _LIBCPP_NEW_DELETE_VIS void operator delete(void* ptr) _NOEXCEPT { @@ -122,21 +122,21 @@ operator delete(void* ptr) _NOEXCEPT ::free(ptr); } -_LIBCPP_WEAK _LIBCPP_FUNC_VIS +_LIBCPP_WEAK _LIBCPP_NEW_DELETE_VIS void operator delete(void* ptr, const std::nothrow_t&) _NOEXCEPT { ::operator delete(ptr); } -_LIBCPP_WEAK _LIBCPP_FUNC_VIS +_LIBCPP_WEAK _LIBCPP_NEW_DELETE_VIS void operator delete[] (void* ptr) _NOEXCEPT { ::operator delete (ptr); } -_LIBCPP_WEAK _LIBCPP_FUNC_VIS +_LIBCPP_WEAK _LIBCPP_NEW_DELETE_VIS void operator delete[] (void* ptr, const std::nothrow_t&) _NOEXCEPT { |