[PATCH] More testsuite cleanup
Jonathan Wakely
jwakely@redhat.com
Mon Aug 1 12:18:00 GMT 2016
Another bunch of fixes to make the testsuite work with any -std
option, and remove some redundancy.
I don't know why this file has "-x c" in the options, but since those
options come after the filename it's ignored and has no effect anyway:
Remove "-x c" from dg-options in libstdc++ C++ test
* testsuite/17_intro/freestanding.cc: Remove "-x c" from dg-options.
Self-explanatory:
Limit std::tuple tests to run for C++11 and later
* testsuite/20_util/tuple/cons/66338.cc: Limit test to C++11 and
later.
* testsuite/20_util/tuple/cons/element_accepts_anything_byval.cc:
Likewise.
Make libstdc++ debug mode test valid for C++98
* testsuite/25_algorithms/lower_bound/debug/irreflexive.cc: Use
C++98-compatible initialization for array.
Remove unused headers and variables from libstdc++ tests
* testsuite/20_util/shared_ptr/assign/auto_ptr_rvalue.cc: Remove
unused header and variable from compile-only test.
* testsuite/20_util/shared_ptr/assign/unique_ptr_rvalue.cc: Likewise.
* testsuite/28_regex/basic_regex/assign/char/cstring.cc: Likewise.
* testsuite/28_regex/basic_regex/ctors/string_wchar_t.cc: Likewise.
* testsuite/experimental/memory/shared_ptr/cons/copy_ctor_neg.cc:
Likewise.
Remove duplicate dg-options directive in string_view test
* testsuite/experimental/string_view/operations/rfind/char/2.cc:
Remove duplicate dg-options directive.
This is just to be consistent with every other pre-C++11 test, so that
grepping for (gnu|c)++98 finds them all:
Use -std=gnu++98 instead of -std=gnu++03 in test
* testsuite/20_util/specialized_algorithms/uninitialized_copy/
808590.cc: Use -std=gnu++98 instead of -std=gnu++03.
The target-specific linker options became redundant a few years ago
when these were changed to use { dg-do compile } (r205766):
Remove linker options from compile-only tests
* testsuite/20_util/make_signed/requirements/typedefs-2.cc: Remove
linker options from compile-only tests.
* testsuite/20_util/make_unsigned/requirements/typedefs-2.cc:
Likewise.
These tests currently use a C++14 alias template, but there's no
reason they can't be run for C++11 mode too:
Run std::ios_base enum tests for C++11 and up
* testsuite/27_io/ios_base/types/fmtflags/case_label.cc: Make test
supported for C++11 and later.
* testsuite/27_io/ios_base/types/iostate/case_label.cc: Likewise.
* testsuite/27_io/ios_base/types/openmode/case_label.cc: Likewise.
(I suppose they could even run for C++98 if we added a preprocessor
check for __cplusplus >= 201103L around the static assertions at the
end.)
Tested powerpc64-linux, committed to trunk.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: patch.txt
Type: text/x-patch
Size: 14828 bytes
Desc: not available
URL: <http://gcc.gnu.org/pipermail/libstdc++/attachments/20160801/e85eabc7/attachment.bin>
More information about the Libstdc++
mailing list