]> Savannah Git Hosting - gnulib.git/commitdiff
stdbool C++ tests: Fix compilation error with MSVC14 (regr. from today).
authorBruno Haible <bruno@clisp.org>
Sat, 10 Sep 2022 22:48:56 +0000 (00:48 +0200)
committerBruno Haible <bruno@clisp.org>
Sat, 10 Sep 2022 22:48:56 +0000 (00:48 +0200)
* tests/test-stdbool-c++.cc (s): Choose field names that are not type
names.

ChangeLog
tests/test-stdbool-c++.cc

index bdec7ddfa270f8518e9d4f902209490e5a3cc19e..5dda053d58a902dcfa18ad0af653cbdd95120169 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,9 @@
 2022-09-10  Bruno Haible  <bruno@clisp.org>
 
+       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 <stdbool.h> if TEST_STDBOOL_H
        is not defined. Add a couple of simple tests, from test-stdbool.c.
index 8e208dfe238dfae05096b19a7cbf8d5c89992652..98358f1ef88c2ffa917f27b84b8b648978bac6b0 100644 (file)
@@ -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];