summaryrefslogtreecommitdiff
path: root/indra/llcorehttp/tests/test_allocator.h
diff options
context:
space:
mode:
authorNat Goodspeed <nat@lindenlab.com>2018-10-25 11:07:43 -0400
committerNat Goodspeed <nat@lindenlab.com>2020-03-25 16:12:46 -0400
commit25a658440dd6f66d64cc146a09ff0725d355bf5c (patch)
tree44bd5870ec021db0bb9bcce915c6206b599eb777 /indra/llcorehttp/tests/test_allocator.h
parent3753dbd5edd3251c12e394cf313015d3120f070c (diff)
DRTVWR-476: Remove throw(T) from operator new(), operator delete().
llcorehttp's test_allocator.{h,cpp} overrides global operator new(), operator new[](), operator delete() and operator delete[](). The two operator new() functions used to be declared with throw(std::bad_alloc). Worse, for VS 2013 and previous, we needed _THROW0() and _THROW1(std::bad_alloc) instead, requiring #if logic. But with dynamic throw declarations deprecated, we must actually remove those. That obviates the THROW_BAD_ALLOC() / THROW_NOTHING() workarounds in test_allocator.cpp.
Diffstat (limited to 'indra/llcorehttp/tests/test_allocator.h')
-rw-r--r--indra/llcorehttp/tests/test_allocator.h11
1 files changed, 2 insertions, 9 deletions
diff --git a/indra/llcorehttp/tests/test_allocator.h b/indra/llcorehttp/tests/test_allocator.h
index 3572bbc5c5..74bd294e47 100644
--- a/indra/llcorehttp/tests/test_allocator.h
+++ b/indra/llcorehttp/tests/test_allocator.h
@@ -31,17 +31,10 @@
#include <new>
size_t GetMemTotal();
-#if defined(WIN32)
-void * operator new(std::size_t size) _THROW1(std::bad_alloc);
-void * operator new[](std::size_t size) _THROW1(std::bad_alloc);
-void operator delete(void * p) _THROW0();
-void operator delete[](void * p) _THROW0();
-#else
-void * operator new(std::size_t size) throw (std::bad_alloc);
-void * operator new[](std::size_t size) throw (std::bad_alloc);
+void * operator new(std::size_t size); //throw (std::bad_alloc);
+void * operator new[](std::size_t size); //throw (std::bad_alloc);
void operator delete(void * p) throw ();
void operator delete[](void * p) throw ();
-#endif
#endif // TEST_ALLOCATOR_H