Add more Linux warnings
MSVC is all bend out of shape about wxString conversions so it will help to get the warnings on Linux as well. Only works for Clang right now
This commit is contained in:
@@ -188,6 +188,13 @@ if( CMAKE_COMPILER_IS_GNUCXX OR CMAKE_CXX_COMPILER_ID MATCHES "Clang" )
|
||||
set( HAVE_WIMPLICIT_FLOAT_CONVERSION true )
|
||||
endif()
|
||||
|
||||
CHECK_CXX_COMPILER_FLAG( "-Wambiguous-conditional" COMPILER_SUPPORTS_WAMBIGUOUS_CONDITIONAL )
|
||||
|
||||
# Add this to match MSVC's warning about ambiguous conditionals
|
||||
if( COMPILER_SUPPORTS_WAMBIGUOUS_CONDITIONAL )
|
||||
set( WARN_FLAGS_CXX "${WARN_FLAGS_CXX} -Wambiguous-conditional" )
|
||||
endif()
|
||||
|
||||
# See if the compiler will throw warnings on these conversions
|
||||
CHECK_CXX_COMPILER_FLAG( "-Wunused-const-variable" COMPILER_SUPPORTS_WUNUSED_CONST_VARIABLE )
|
||||
|
||||
|
||||
Reference in New Issue
Block a user