From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 2181) id 0819B3858427; Wed, 25 Aug 2021 23:08:30 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 0819B3858427 MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset="utf-8" From: Jonathan Wakely To: gcc-cvs@gcc.gnu.org, libstdc++-cvs@gcc.gnu.org Subject: [gcc r12-3149] libstdc++: Fix names.cc test failures on Windows X-Act-Checkin: gcc X-Git-Author: Jonathan Wakely X-Git-Refname: refs/heads/master X-Git-Oldrev: 0163bbaaef119ef9e98c4b3dcba159609f77c818 X-Git-Newrev: f1a08f4d7839a0197a28ecd9ca6d4400769da3a7 Message-Id: <20210825230830.0819B3858427@sourceware.org> Date: Wed, 25 Aug 2021 23:08:30 +0000 (GMT) X-BeenThere: gcc-cvs@gcc.gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gcc-cvs mailing list List-Unsubscribe: , List-Archive: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 25 Aug 2021 23:08:30 -0000 https://gcc.gnu.org/g:f1a08f4d7839a0197a28ecd9ca6d4400769da3a7 commit r12-3149-gf1a08f4d7839a0197a28ecd9ca6d4400769da3a7 Author: Jonathan Wakely Date: Wed Aug 25 22:27:22 2021 +0100 libstdc++: Fix names.cc test failures on Windows The Windows CRT headers define structs with members called f, x, y etc so don't check those. There are also lots of unnecessary function parameters in mingw headers using non-reserved names, e.g. uses p and z as parameters of mingw_gettimeofday uses j as a parameter of imaxabs uses l, o and func as parameter names Those should be fixed in the headers instead. Signed-off-by: Jonathan Wakely libstdc++-v3/ChangeLog: * testsuite/17_intro/names.cc: Adjust for Windows. Diff: --- libstdc++-v3/testsuite/17_intro/names.cc | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/libstdc++-v3/testsuite/17_intro/names.cc b/libstdc++-v3/testsuite/17_intro/names.cc index 3cbe0d2da54..b0cc21d6cda 100644 --- a/libstdc++-v3/testsuite/17_intro/names.cc +++ b/libstdc++-v3/testsuite/17_intro/names.cc @@ -287,4 +287,14 @@ #endif // __VXWORKS__ +#ifdef _WIN32 +#undef Value +// defines _CRT_FLOAT::f +#undef f +// defines _CRT_DOUBLE::x and _LONGDOUBLE::x +#undef x +// defines _complex::x and _complex::y +#undef y +#endif + #include