mirror of
https://github.com/catchorg/Catch2.git
synced 2025-08-02 21:35:40 +02:00
Add Wfloat-equal to default-enabled warnings
This is kinda messy, because there is no good way to signal to the compiler that some code uses direct comparison of floating point numbers intentionally, so instead we have to use diagnostic pragmas. We also have to over-suppress the test files, because Clang (and possibly GCC) still issue warnings from template instantiation even if the instantion site is under warning suppression, so the template definition has to be under warning suppression as well. Closes #2406
This commit is contained in:
@@ -56,6 +56,7 @@ function(add_warnings_to_targets targets)
|
||||
"-Wexit-time-destructors"
|
||||
"-Wextra"
|
||||
"-Wextra-semi"
|
||||
"-Wfloat-equal"
|
||||
"-Wglobal-constructors"
|
||||
"-Winit-self"
|
||||
"-Wmisleading-indentation"
|
||||
|
Reference in New Issue
Block a user