]> git.ipfire.org Git - thirdparty/binutils-gdb.git/commitdiff
Rely on C++17 <new> in new-op.cc
authorTom Tromey <tom@tromey.com>
Sun, 15 Oct 2023 18:16:12 +0000 (12:16 -0600)
committerTom Tromey <tom@tromey.com>
Wed, 29 Nov 2023 21:29:44 +0000 (14:29 -0700)
gdbsupport/new-op.cc has a comment about relying on the C++-17 <new>
header.  This patch implements the suggestion.

Approved-By: Pedro Alves <pedro@palves.net>
gdbsupport/new-op.cc

index 6a056ef508f115790ef953c873f618d29733b52b..181fc4957fa95a0fd662ce13f14400114f63ba0f 100644 (file)
 #include "host-defs.h"
 #include <new>
 
-/* These are declared in <new> starting C++14.  Add these here to enable
-   compilation using C++11. */
-extern void operator delete (void *p, std::size_t) noexcept;
-extern void operator delete[] (void *p, std::size_t) noexcept;
-
 /* Override operator new / operator new[], in order to internal_error
    on allocation failure and thus query the user for abort/core
    dump/continue, just like xmalloc does.  We don't do this from a