mirror of
https://github.com/XRPLF/rippled.git
synced 2025-11-29 07:25:51 +00:00
Fix shadowing variables
This commit is contained in:
@@ -547,6 +547,12 @@ if (MSVC)
|
||||
else ()
|
||||
# HACK : because these need to come first, before any warning demotion
|
||||
string (APPEND CMAKE_CXX_FLAGS " -Wall -Wdeprecated")
|
||||
if (is_clang OR (is_gcc AND NOT unity))
|
||||
# gcc flags many more instances with `-Wshadow` than clang. Many incouous
|
||||
# shadowings are flagged in unity mode. Only turn on gcc warnings in nonunity
|
||||
# builds
|
||||
string (APPEND CMAKE_CXX_FLAGS " -Wshadow")
|
||||
endif()
|
||||
# not MSVC
|
||||
target_compile_options (common
|
||||
INTERFACE
|
||||
|
||||
Reference in New Issue
Block a user