Skip to content

Commit 87d1f4c

Browse files
authored
Merge pull request #480 from boostorg/479
Ignore c2y-extensions warning with Clang >= 22
2 parents 391fbad + 2818ef3 commit 87d1f4c

1 file changed

Lines changed: 9 additions & 0 deletions

File tree

include/boost/test/unit_test_suite.hpp

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -348,6 +348,11 @@ typedef ::boost::unit_test::ut_detail::nil_t BOOST_AUTO_TEST_CASE_FIXTURE;
348348
// ************** Auto registration facility helper macros ************** //
349349
// ************************************************************************** //
350350

351+
#if defined(__clang__) && __clang_major__ >= 22
352+
# pragma clang diagnostic push
353+
# pragma clang diagnostic ignored "-Wc2y-extensions"
354+
#endif
355+
351356
// Facility for having a unique name based on __LINE__ and __COUNTER__ (later if available)
352357
#if defined(__COUNTER__)
353358
#define BOOST_TEST_INTERNAL_HAS_COUNTER
@@ -364,6 +369,10 @@ typedef ::boost::unit_test::ut_detail::nil_t BOOST_AUTO_TEST_CASE_FIXTURE;
364369
#endif
365370
/**/
366371

372+
#if defined(__clang__) && __clang_major__ >= 22
373+
# pragma clang diagnostic pop
374+
#endif
375+
367376
#define BOOST_AUTO_TU_REGISTRAR( test_name ) \
368377
static boost::unit_test::ut_detail::auto_test_unit_registrar \
369378
BOOST_TEST_APPEND_UNIQUE_ID( BOOST_JOIN( test_name, _registrar ) ) BOOST_ATTRIBUTE_UNUSED \

0 commit comments

Comments
 (0)