[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[lmi-commits] [lmi] master 9a551769 22/24: Disable floating-point compar
From: |
Greg Chicares |
Subject: |
[lmi-commits] [lmi] master 9a551769 22/24: Disable floating-point comparison warning |
Date: |
Fri, 8 Jul 2022 07:11:28 -0400 (EDT) |
branch: master
commit 9a5517696e77604217077e5330724670eb62d06b
Author: Gregory W. Chicares <gchicares@sbcglobal.net>
Commit: Gregory W. Chicares <gchicares@sbcglobal.net>
Disable floating-point comparison warning
Incidentally, explain it the same way for both compilers.
---
compiler_clang_warnings.make | 1 +
compiler_gcc_warnings.make | 3 +--
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/compiler_clang_warnings.make b/compiler_clang_warnings.make
index 4959948c..fdeaa9db 100644
--- a/compiler_clang_warnings.make
+++ b/compiler_clang_warnings.make
@@ -47,6 +47,7 @@ clang_c_warnings := \
# Write '-Wno' options at the end, with a rationale here.
#
+# -Wfloat-equal: too many false positives, e.g., 0.0 == X
# -Wlogical-op-parentheses: && is multiplicative; || is additive
# -Wmismatched-tags: stylistic freedom--not a defect
# -Wpadded: useful only for low-level work
diff --git a/compiler_gcc_warnings.make b/compiler_gcc_warnings.make
index 0a647387..546f4950 100644
--- a/compiler_gcc_warnings.make
+++ b/compiler_gcc_warnings.make
@@ -51,8 +51,7 @@ endif
# -Wabi: useful only for a special purpose
# -Wanalyzer-too-complex: not actually helpful
# -Wdate-time: only for "bit-wise-identical reproducible compilations"
-# -Wfloat-equal: too many warnings on correct code, e.g.,
-# exact comparison to zero
+# -Wfloat-equal: too many false positives, e.g., 0.0 == X
# -Winline: 'inline' now refers to linkage, not inlining
# -Wmissing-declarations: for C++, this flags valid functions that
# arguably belong in an unnamed namespace
- [lmi-commits] [lmi] master a5e06004 14/24: Enable another clang warning, except for cgicc, (continued)
- [lmi-commits] [lmi] master a5e06004 14/24: Enable another clang warning, except for cgicc, Greg Chicares, 2022/07/08
- [lmi-commits] [lmi] master c21d8849 12/24: Explain why certain clang warnings will remain disabled, Greg Chicares, 2022/07/08
- [lmi-commits] [lmi] master e5eeed14 20/24: Explain why two more clang warnings are disabled, Greg Chicares, 2022/07/08
- [lmi-commits] [lmi] master f8fac8dd 24/24: Explain why several more clang warnings are disabled, Greg Chicares, 2022/07/08
- [lmi-commits] [lmi] master 06f81a9c 05/24: Refine warning pragmata, Greg Chicares, 2022/07/08
- [lmi-commits] [lmi] master 32145870 03/24: Correct an inconsistency in a comment, Greg Chicares, 2022/07/08
- [lmi-commits] [lmi] master 5334fa49 04/24: Prefer 'nullptr' to '0', Greg Chicares, 2022/07/08
- [lmi-commits] [lmi] master e7ef946d 11/24: Disable a warning only for cgicc, Greg Chicares, 2022/07/08
- [lmi-commits] [lmi] master e97c7ec6 17/24: Enable another clang warning, with one pragmatic exception, Greg Chicares, 2022/07/08
- [lmi-commits] [lmi] master b5cee829 18/24: Explain why '-Wpadded' is disabled for clang, Greg Chicares, 2022/07/08
- [lmi-commits] [lmi] master 9a551769 22/24: Disable floating-point comparison warning,
Greg Chicares <=
- [lmi-commits] [lmi] master bb0434c3 09/24: Avoid clang warning on silliness, Greg Chicares, 2022/07/08
- [lmi-commits] [lmi] master 17c9b8e0 16/24: Enable another clang warning, except for cgicc, Greg Chicares, 2022/07/08
- [lmi-commits] [lmi] master 1be7d13d 23/24: Don't let clang warn about lawful comments, Greg Chicares, 2022/07/08
- [lmi-commits] [lmi] master 29fec503 13/24: Work around spurious clang "unused" warnings, Greg Chicares, 2022/07/08
- [lmi-commits] [lmi] master 89930e76 15/24: Experimentally work around a clang warning, Greg Chicares, 2022/07/08
- [lmi-commits] [lmi] master 06024f1f 19/24: '-Wold-style-cast': treat clang the same as gcc, Greg Chicares, 2022/07/08
- [lmi-commits] [lmi] master 6a5c4bb3 21/24: Distinguish gcc vs. clang floating-point warnings, Greg Chicares, 2022/07/08