]> git.ipfire.org Git - thirdparty/binutils-gdb.git/commit
[gdb/testsuite] Fix gdb.base/infcall-nested-structs.c regression
authorTom de Vries <tdevries@suse.de>
Sat, 21 Feb 2026 21:38:30 +0000 (22:38 +0100)
committerTom de Vries <tdevries@suse.de>
Sat, 21 Feb 2026 21:38:30 +0000 (22:38 +0100)
commite06358a0c13a86a7f576c3f024795a031f9c4be2
tree21420194a07b56c2f23f0aac14266d23e2518de0
parent67732d2f41269183e6ec99e585c703928a0027cf
[gdb/testsuite] Fix gdb.base/infcall-nested-structs.c regression

Since commit 120072c7cdc ("gdb/testsuite: update C++ tests for volatile
changes in C++20") I see regressions in two test-cases:
...
$ ./sum.sh
   4300 gdb.base/infcall-nested-structs-c++.exp:
   2500 gdb.base/infcall-nested-structs-c.exp:
...

In more detail, in test-case gdb.base/infcall-nested-structs-c++.exp:
...
(gdb) tbreak 421^M
No compiled code for line 421 in the current file.^M
Make breakpoint pending on future shared library load? (y or [n]) n^M
(gdb) FAIL: $exp: types-tc: gdb_breakpoint: set breakpoint at 421
...

Fix this by reverting the change done by the commit, and applying the same fix
as the commit applied elsewhere:
...
-  v++;
+  v = v + 1;
...

Tested on x86_64-linux, with target boards unix and unix/-std=c++20.

Approved-By: Andrew Burgess <aburgess@redhat.com>
Bug: https://sourceware.org/bugzilla/show_bug.cgi?id=33915
gdb/testsuite/gdb.base/infcall-nested-structs.c