]> git.eshelyaron.com Git - emacs.git/commitdiff
Ignore fewer GCC -fanalyzer diagnostics in ccl.c
authorPaul Eggert <eggert@cs.ucla.edu>
Sun, 18 Feb 2024 07:12:18 +0000 (23:12 -0800)
committerEshel Yaron <me@eshelyaron.com>
Wed, 28 Feb 2024 17:35:43 +0000 (18:35 +0100)
* src/ccl.c: Do not ignore -Wanalyzer-use-of-uninitialized-value,
as that bug has been fixed in GCC.  Ignore
-Wanalyzer-out-of-bounds only if GCC 13, as the bug will
reportedly be fixed when GCC 14 comes out.

(cherry picked from commit f8d27a8a1fd5bdc8e25569cc05a9298e186a8c63)

src/ccl.c

index a3a03a5b7b173a54a584ce485f8b9d8666cd61a5..8bb8a78fe3def801662bcc88c25bf78d8c42b69a 100644 (file)
--- a/src/ccl.c
+++ b/src/ccl.c
@@ -35,11 +35,6 @@ along with GNU Emacs.  If not, see <https://www.gnu.org/licenses/>.  */
 #include "coding.h"
 #include "keyboard.h"
 
-/* Avoid GCC 12 bug <https://gcc.gnu.org/bugzilla/show_bug.cgi?id=105784>.  */
-#if GNUC_PREREQ (12, 0, 0)
-# pragma GCC diagnostic ignored "-Wanalyzer-use-of-uninitialized-value"
-#endif
-
 /* Table of registered CCL programs.  Each element is a vector of
    NAME, CCL_PROG, RESOLVEDP, and UPDATEDP, where NAME (symbol) is the
    name of the program, CCL_PROG (vector) is the compiled code of the
@@ -609,7 +604,7 @@ while (0)
    https://gcc.gnu.org/bugzilla/show_bug.cgi?id=109579
    which causes GCC to mistakenly complain about
    popping the mapping stack.  */
-#if GNUC_PREREQ (13, 0, 0)
+#if __GNUC__ == 13
 # pragma GCC diagnostic ignored "-Wanalyzer-out-of-bounds"
 #endif