From: Bruno Haible Date: Sat, 10 Sep 2022 22:48:56 +0000 (+0200) Subject: stdbool C++ tests: Fix compilation error with MSVC14 (regr. from today). X-Git-Tag: v1.0~2039 X-Git-Url: https://gitweb.git.savannah.gnu.org/gitweb/?a=commitdiff_plain;h=60e9cc86d91d23465bb79751c772ec87d05bae13;p=gnulib.git stdbool C++ tests: Fix compilation error with MSVC14 (regr. from today). * tests/test-stdbool-c++.cc (s): Choose field names that are not type names. --- diff --git a/ChangeLog b/ChangeLog index bdec7ddfa2..5dda053d58 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,9 @@ 2022-09-10 Bruno Haible + stdbool C++ tests: Fix compilation error with MSVC14 (regr. from today). + * tests/test-stdbool-c++.cc (s): Choose field names that are not type + names. + Reorganize C++ tests for stdbool and stdbool-c99. * tests/test-stdbool-c++.cc: Don't include if TEST_STDBOOL_H is not defined. Add a couple of simple tests, from test-stdbool.c. diff --git a/tests/test-stdbool-c++.cc b/tests/test-stdbool-c++.cc index 8e208dfe23..98358f1ef8 100644 --- a/tests/test-stdbool-c++.cc +++ b/tests/test-stdbool-c++.cc @@ -33,7 +33,7 @@ "error: true is not 1" #endif -struct s { bool s: 1; bool t; } s; +struct s { bool u: 1; bool v; } s; char a[true == 1 ? 1 : -1]; char b[false == 0 ? 1 : -1];