]> git.ipfire.org Git - thirdparty/gcc.git/commit
libstdc++: Add xfail to pretty printer tests that fail in C++20
authorJonathan Wakely <jwakely@redhat.com>
Fri, 5 Nov 2021 11:25:27 +0000 (11:25 +0000)
committerJonathan Wakely <jwakely@redhat.com>
Tue, 14 Jun 2022 19:20:03 +0000 (20:20 +0100)
commit1d2336f8465ff3a3a8b723367d5305774deb3f86
tree297b1ac967b5d60c2b756edf2675ffafef021e2d
parent4c6e66a4dba5bbbcf343c1f6a58f355e270e79b9
libstdc++: Add xfail to pretty printer tests that fail in C++20

For some reason the type printer for std::string doesn't work in C++20
mode, so std::basic_string<char, char_traits<char>, allocator<char> is
printed out in full rather than being shown as std::string. It's
probably related to the fact that the extern template declarations are
disabled for C++20, but I don't know why that affects GDB.

For now I'm just marking the relevant tests as XFAIL. That requires
adding support for target selectors to individual GDB directives such as
note-test and whatis-regexp-test.

libstdc++-v3/ChangeLog:

* testsuite/lib/gdb-test.exp: Add target selector support to the
dg-final directives.
* testsuite/libstdc++-prettyprinters/80276.cc: Add xfail for
C++20.
* testsuite/libstdc++-prettyprinters/libfundts.cc: Likewise.
* testsuite/libstdc++-prettyprinters/prettyprinters.exp: Tweak
comment.

(cherry picked from commit 30b8ec68e2a7731ab28e6fd1512c1c631f086676)
libstdc++-v3/testsuite/lib/gdb-test.exp
libstdc++-v3/testsuite/libstdc++-prettyprinters/80276.cc
libstdc++-v3/testsuite/libstdc++-prettyprinters/libfundts.cc
libstdc++-v3/testsuite/libstdc++-prettyprinters/prettyprinters.exp