Skip to content

Commit b3a2653

Browse files
committed
[skip ci] Allow to use -DBOOLEAN_TEST_NODISCARD=1
1 parent f6913c1 commit b3a2653

File tree

4 files changed

+7
-4
lines changed

4 files changed

+7
-4
lines changed

test/boolean.t.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -177,7 +177,7 @@ CASE( "boolean: Allows to compare greater than or equal with bool (C++11)" )
177177

178178
CASE( "boolean: Supports no discard (C++17, -DBOOLEAN_TEST_NODISCARD=1)" )
179179
{
180-
#ifdef BOOLEAN_TEST_NODISCARD
180+
#if defined BOOLEAN_TEST_NODISCARD && BOOLEAN_TEST_NODISCARD
181181
boolean_ f( false );
182182
boolean_ t( true );
183183

test/t.bat

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,8 @@ call :CompilerVersion version
1515
echo VC%version%: %args%
1616

1717
set unit_config=^
18-
-Dboolean_BOOLEAN_HEADER=\"nonstd/boolean.hpp\"
18+
-Dboolean_BOOLEAN_HEADER=\"nonstd/boolean.hpp\" ^
19+
-DBOOLEAN_TEST_NODISCARD=1
1920

2021
set msvc_defines=^
2122
-D_CRT_SECURE_NO_WARNINGS ^

test/tc.bat

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,8 @@ call :CompilerVersion version
1717
echo %clang% %version%: %std%
1818

1919
set unit_config=^
20-
-Dboolean_BOOLEAN_HEADER=\"nonstd/boolean.hpp\"
20+
-Dboolean_BOOLEAN_HEADER=\"nonstd/boolean.hpp\" ^
21+
-DBOOLEAN_TEST_NODISCARD=0
2122

2223
rem -flto / -fwhole-program
2324
set optflags=-O2

test/tg.bat

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,8 @@ call :CompilerVersion version
1818
echo %gpp% %version%: %std% %args%
1919

2020
set unit_config=^
21-
-Dboolean_BOOLEAN_HEADER=\"nonstd/boolean.hpp\"
21+
-Dboolean_BOOLEAN_HEADER=\"nonstd/boolean.hpp\" ^
22+
-DBOOLEAN_TEST_NODISCARD=0
2223

2324
rem -flto / -fwhole-program
2425
set optflags=-O2

0 commit comments

Comments
 (0)