Adjust C++ destructor type tests

Message ID 20240510203409.1897598-1-jason@redhat.com
State New
Headers
Series Adjust C++ destructor type tests |

Checks

Context Check Description
linaro-tcwg-bot/tcwg_gdb_build--master-aarch64 success Testing passed
linaro-tcwg-bot/tcwg_gdb_build--master-arm success Testing passed
linaro-tcwg-bot/tcwg_gdb_check--master-arm success Testing passed
linaro-tcwg-bot/tcwg_gdb_check--master-aarch64 success Testing passed

Commit Message

Jason Merrill May 10, 2024, 8:33 p.m. UTC
  In gcc-15-95-ga12cae97390 I dropped the unnecessary artificial "in-charge"
parameter from destructors of classes with no virtual bases; Linaro's CI
informed me that the gdb testsuite needs to be adjusted to match.

Teested against GCC 13.2 and GCC 15 trunk.
---
 gdb/testsuite/gdb.cp/m-static.exp | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)


base-commit: e14f6ec969d788b73ac61f61e8c623536cda1cad
  

Comments

Kevin Buettner May 11, 2024, 9:56 p.m. UTC | #1
On Fri, 10 May 2024 16:33:20 -0400
Jason Merrill <jason@redhat.com> wrote:

> In gcc-15-95-ga12cae97390 I dropped the unnecessary artificial "in-charge"
> parameter from destructors of classes with no virtual bases; Linaro's CI
> informed me that the gdb testsuite needs to be adjusted to match.
> 
> Teested against GCC 13.2 and GCC 15 trunk.

LGTM.

Approved-by: Kevin Buettner <kevinb@redhat.com>
  
Tom Tromey May 14, 2024, 2:40 p.m. UTC | #2
>>>>> "Jason" == Jason Merrill <jason@redhat.com> writes:

Jason> In gcc-15-95-ga12cae97390 I dropped the unnecessary artificial "in-charge"
Jason> parameter from destructors of classes with no virtual bases; Linaro's CI
Jason> informed me that the gdb testsuite needs to be adjusted to match.

Jason> Teested against GCC 13.2 and GCC 15 trunk.

I went ahead & pushed this.

Tom
  

Patch

diff --git a/gdb/testsuite/gdb.cp/m-static.exp b/gdb/testsuite/gdb.cp/m-static.exp
index 19eb70b7d71..45bc090d01f 100644
--- a/gdb/testsuite/gdb.cp/m-static.exp
+++ b/gdb/testsuite/gdb.cp/m-static.exp
@@ -79,14 +79,14 @@  if { [is_aarch32_target] } {
 	"simple object class, ptype constructor"
 
     gdb_test "print test1.~gnu_obj_1" \
-	{ = {void \*\(gnu_obj_1 \* const, int\)} 0x[0-9a-f]+ <gnu_obj_1::~gnu_obj_1\(\)>} \
+	{ = {void \*\(gnu_obj_1 \* const(, int)?\)} 0x[0-9a-f]+ <gnu_obj_1::~gnu_obj_1\(\)>} \
 	"simple object instance, print destructor"
     gdb_test "ptype test1.~gnu_obj_1" \
-	{type = void \*\(gnu_obj_1 \* const, int\)} \
+	{type = void \*\(gnu_obj_1 \* const(, int)?\)} \
 	"simple object instance, ptype destructor"
 
     gdb_test "print test1.'~gnu_obj_1'" \
-	{ = {void \*\(gnu_obj_1 \*( const)?, int\)} 0x[0-9a-f]+ <gnu_obj_1::~gnu_obj_1\(\)>} \
+	{ = {void \*\(gnu_obj_1 \*( const)?(, int)?\)} 0x[0-9a-f]+ <gnu_obj_1::~gnu_obj_1\(\)>} \
 	"simple object instance, print quoted destructor"
 
     gdb_test "ptype gnu_obj_1::'~gnu_obj_1'" \