This change also fixes icc builds: Commit
39cca4e missed noexcept
specification for nothrow variants of new and delete operators,
and the icc compiler did not like that.
Furthermore, we can simplify the replacements because, according
to cppreference, with C++11, "replacing the throwing single object
allocation functions is sufficient to handle all [allocations and
deallocations]".
{
xfree(address);
}
-void *operator new[](size_t size)
-{
- return xmalloc(size);
-}
-void operator delete[](void *address)
-{
- xfree(address);
-}
-
-void *operator new(size_t size, const std::nothrow_t &tag)
-{
- return xmalloc(size);
-}
-void operator delete(void *address, const std::nothrow_t &tag)
-{
- xfree(address);
-}
-void *operator new[](size_t size, const std::nothrow_t &tag)
-{
- return xmalloc(size);
-}
-void operator delete[](void *address, const std::nothrow_t &tag)
-{
- xfree(address);
-}
#endif /* !defined(__clang__) */