diff mbox series

fix testsuite/g++.dg/init/new26.C for C++-14 and later

Message ID ortusdh64l.fsf@lxoliva.fsfla.org
State New
Headers show
Series fix testsuite/g++.dg/init/new26.C for C++-14 and later | expand

Commit Message

Alexandre Oliva Dec. 22, 2020, 9:40 p.m. UTC
This test fails during the execution on VxWorks 7 when using
C++-14 and C++-17.

Regstrapped on x86_64-linux-gnu, and tested with -x-arm-wrs-vxworks7r2.
Ok to install?


from Jerome Lambourg <lambourg@adacore.com>
for  gcc/testsuite/ChangeLog

	* g++.dg/init/new26.C: Fix overriding of the delete operator
	for c++14 profile.
---
 gcc/testsuite/g++.dg/init/new26.C |    4 ++++
 1 file changed, 4 insertions(+)

Comments

Mike Stump Dec. 29, 2020, 7:19 p.m. UTC | #1
On Dec 22, 2020, at 1:40 PM, Alexandre Oliva <oliva@adacore.com> wrote:
> 
> This test fails during the execution on VxWorks 7 when using
> C++-14 and C++-17.
> 
> Regstrapped on x86_64-linux-gnu, and tested with -x-arm-wrs-vxworks7r2.
> Ok to install?

Ok.
diff mbox series

Patch

diff --git a/gcc/testsuite/g++.dg/init/new26.C b/gcc/testsuite/g++.dg/init/new26.C
index 541de3058e10a..75bdcb15074d5 100644
--- a/gcc/testsuite/g++.dg/init/new26.C
+++ b/gcc/testsuite/g++.dg/init/new26.C
@@ -16,8 +16,12 @@  inline void *operator new(__SIZE_TYPE__)
   return p;
 }
 
+// C++11 and earlier
 inline void operator delete (void*) {}
 
+// C++14 profile
+inline void operator delete (void*, __SIZE_TYPE__) {}
+
 int * __attribute__((noinline)) doit(int n)
 {
   float *q;