public inbox for gcc-cvs@sourceware.org help / color / mirror / Atom feed
From: Jonathan Wakely <redi@gcc.gnu.org> To: gcc-cvs@gcc.gnu.org, libstdc++-cvs@gcc.gnu.org Subject: [gcc r12-1814] libstdc++: More workarounds in 17_intro/names.cc test [PR 97088] Date: Fri, 25 Jun 2021 19:50:53 +0000 (GMT) [thread overview] Message-ID: <20210625195053.AB83F385E00E@sourceware.org> (raw) https://gcc.gnu.org/g:e83a5a6b6893e910dc0b6b1cd034e1a258406c93 commit r12-1814-ge83a5a6b6893e910dc0b6b1cd034e1a258406c93 Author: Jonathan Wakely <jwakely@redhat.com> Date: Fri Jun 25 18:31:22 2021 +0100 libstdc++: More workarounds in 17_intro/names.cc test [PR 97088] Conditionally #undef some more names that are used in system headers. libstdc++-v3/ChangeLog: PR libstdc++/97088 * testsuite/17_intro/names.cc: Undef more names for newlib and also for arm-none-linux-gnueabi. * testsuite/experimental/names.cc: Disable PCH. Diff: --- libstdc++-v3/testsuite/17_intro/names.cc | 14 ++++++++++++++ libstdc++-v3/testsuite/experimental/names.cc | 1 + 2 files changed, 15 insertions(+) diff --git a/libstdc++-v3/testsuite/17_intro/names.cc b/libstdc++-v3/testsuite/17_intro/names.cc index 534dab70ff5..805c1002c3f 100644 --- a/libstdc++-v3/testsuite/17_intro/names.cc +++ b/libstdc++-v3/testsuite/17_intro/names.cc @@ -208,6 +208,11 @@ #undef r #endif +#if defined (__linux__) && defined (__arm__) +// <sys/ucontext.h> defines fpregset_t::fpregs::j +#undef j +#endif + #if defined (__linux__) && defined (__powerpc__) // <asm/types.h> defines __vector128::u #undef u @@ -220,6 +225,15 @@ #if ! __has_include(<newlib.h>) // newlib's <sys/cdefs.h> defines __lockable as a macro, so we can't use it. # define __lockable cannot be used as an identifier +// newlib's <time.h> defines __tzrule_type with these members. +#undef d +#undef m +#undef n +#undef s +// newlib's <math.h> uses this for parameters +#undef x +// newlib's <inttypes.h> uses this for parameters +#undef j #endif #ifdef __sun__ diff --git a/libstdc++-v3/testsuite/experimental/names.cc b/libstdc++-v3/testsuite/experimental/names.cc index 34ec3ba5968..d695a258f2c 100644 --- a/libstdc++-v3/testsuite/experimental/names.cc +++ b/libstdc++-v3/testsuite/experimental/names.cc @@ -16,6 +16,7 @@ // <http://www.gnu.org/licenses/>. // { dg-do compile { target c++11 } } +// { dg-add-options no_pch } // Define macros for some common variables names that we must not use for // naming variables, parameters etc. in the library.
reply other threads:[~2021-06-25 19:50 UTC|newest] Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=20210625195053.AB83F385E00E@sourceware.org \ --to=redi@gcc.gnu.org \ --cc=gcc-cvs@gcc.gnu.org \ --cc=libstdc++-cvs@gcc.gnu.org \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: linkBe sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).