GNU bug report logs -
#75964
Switching the Emacs build to -Wswitch-enum in src/
Previous Next
Full log
View this message in rfc822 format
On 2025-02-02 00:21, Pip Cet wrote:
> emacs_abort () isn't equivalent to eassert (false), and that's
> always been confusing to me.
The inspiration is emacs_abort : abort :: eassert : assert. If we made
emacs_abort () equivalent to eassert (false) we'd break that, as in C
abort () is not equivalent to assert (false).
> can't we just enable
> -Wswitch-enum and people live with what they get?
Yes, if the new -Wswitch-enum behavior is in stable GCC and if Emacs
compiles cleanly with the new GCC. Come to think of it, that'd be better
than autoconfery.
In other words, I'm thinking that the change to Emacs can wait until GCC
is fixed, and once that happens we can change Emacs. We shouldn't need
to fiddle with configure.ac or with Makefiles or whatever, other than to
add -Wswitch-enum.
This bug report was last modified 127 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.