From b1e30beb2ee3a86fc29af57f678ee07641f1a32d Mon Sep 17 00:00:00 2001 From: Juan Cruz Viotti Date: Thu, 5 Sep 2024 11:20:07 -0400 Subject: [PATCH] Shut off GCC invalif dangling reference warnings Signed-off-by: Juan Cruz Viotti --- cmake/noa/compiler/options.cmake | 3 +++ 1 file changed, 3 insertions(+) diff --git a/cmake/noa/compiler/options.cmake b/cmake/noa/compiler/options.cmake index c859781..b192a64 100644 --- a/cmake/noa/compiler/options.cmake +++ b/cmake/noa/compiler/options.cmake @@ -69,5 +69,8 @@ function(noa_add_default_options visibility target) -Wcomma -Wno-exit-time-destructors -Wrange-loop-analysis) + elseif(NOA_COMPILER_GCC) + # Newer versions of GCC (i.e. 14) seem to print a lot of false-positives here + target_compile_options("${target}" ${visibility} -Wno-dangling-reference) endif() endfunction()