Skip to content

Commit d2e55ed

Browse files
committed
add pragma for gcc13
1 parent 30003ef commit d2e55ed

File tree

1 file changed

+13
-0
lines changed

1 file changed

+13
-0
lines changed

source/bxdatatools/testing/test_reflection_0.cxx

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -369,7 +369,20 @@ void test_logger (bool /*debug_*/)
369369
std::clog << "Does not exist: " << "datatools::logger::property" << std::endl;
370370
}
371371

372+
#if defined(__GNUC__)
373+
#if __GNUC_VERSION__ >= 130000
374+
// #pragma message "Applying special diagnostic ignored '-Wdangling-reference'"
375+
#pragma GCC diagnostic push
376+
#pragma GCC diagnostic ignored "-Wdangling-reference"
377+
#endif
378+
#endif
372379
const camp::Enum & tMetaEnum = camp::enumByName("datatools::logger::priority");
380+
#if defined(__GNUC__)
381+
#if __GNUC_VERSION__ >= 130000
382+
// #pragma message "Applying special diagnostic ignored '-Wdangling-reference'"
383+
#pragma GCC diagnostic pop
384+
#endif
385+
#endif
373386
for (int i = 0; i < (int) tMetaEnum.size(); i++) {
374387
std::clog << " - Key '" << tMetaEnum.pair(i).name
375388
<< "' has value = " << tMetaEnum.pair(i).value << std::endl;

0 commit comments

Comments
 (0)