Skip to content

Commit fe2a20a

Browse files
committed
Fix warning suppression block in Condition.tests straddling includes
1 parent 51b0532 commit fe2a20a

1 file changed

Lines changed: 10 additions & 9 deletions

File tree

tests/SelfTest/UsageTests/Condition.tests.cpp

Lines changed: 10 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -6,15 +6,6 @@
66

77
// SPDX-License-Identifier: BSL-1.0
88

9-
#ifdef __clang__
10-
# pragma clang diagnostic push
11-
# pragma clang diagnostic ignored "-Wpadded"
12-
// Wdouble-promotion is not supported until 3.8
13-
# if (__clang_major__ > 3) || (__clang_major__ == 3 && __clang_minor__ > 7)
14-
# pragma clang diagnostic ignored "-Wdouble-promotion"
15-
# endif
16-
#endif
17-
189
#include <catch2/catch_approx.hpp>
1910
#include <catch2/catch_test_macros.hpp>
2011

@@ -24,6 +15,16 @@ using Catch::Approx;
2415
#include <limits>
2516
#include <cstdint>
2617

18+
#ifdef __clang__
19+
# pragma clang diagnostic push
20+
# pragma clang diagnostic ignored "-Wpadded"
21+
// Wdouble-promotion is not supported until 3.8
22+
# if ( __clang_major__ > 3 ) || \
23+
( __clang_major__ == 3 && __clang_minor__ > 7 )
24+
# pragma clang diagnostic ignored "-Wdouble-promotion"
25+
# endif
26+
#endif
27+
2728
namespace {
2829

2930
struct TestData {

0 commit comments

Comments
 (0)