emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: C-g crash in C-x C-f (OSX Lion)


From: Jan Djärv
Subject: Re: C-g crash in C-x C-f (OSX Lion)
Date: Mon, 19 Dec 2011 19:18:27 +0100

Hello.

I get a lot of "will never be executed" for the macro SELECTED_FRAME:

#define SELECTED_FRAME()                                \
     ((FRAMEP (selected_frame)                          \
       && FRAME_LIVE_P (XFRAME (selected_frame)))       \
      ? XFRAME (selected_frame)                         \
      : (abort (), (struct frame *) 0))

I guess it is the (struct frame *)0 that never will be executed?
How do you deal with these warnings?

        Jan D.

17 dec 2011 kl. 19:19 skrev Paul Eggert:

> On 12/17/11 01:14, Jan Djärv wrote:
>> Did you use gcc for the static checking?  Which options?
> 
> Yes, I used gcc.  Here are the options I typically use
> for Emacs on Fedora 15.  I also use -isystem
> rather than -I for system include directories.
> I have a modified configure.in that enables all this
> with --enable-gcc-warnings (this is the typical 'configure' option
> for other GNU packages).  I'm planning to add this 'configure'
> option to Emacs at some point, so that others can do this sort
> of checking if they want to.
> 
> -std=gnu99
> -Wall
> -W
> -Wformat-y2k
> -Wformat-security
> -Winit-self
> -Wmissing-include-dirs
> -Wunused
> -Wunknown-pragmas
> -Wstrict-aliasing
> -Wdeclaration-after-statement
> -Wunsafe-loop-optimizations
> -Wpointer-arith
> -Wbad-function-cast
> -Wcast-align
> -Wwrite-strings
> -Wlogical-op
> -Wstrict-prototypes
> -Wold-style-definition
> -Wmissing-prototypes
> -Wmissing-declarations
> -Wmissing-noreturn
> -Wmissing-format-attribute
> -Wpacked
> -Wunreachable-code
> -Winvalid-pch
> -Wvolatile-register-var
> -Wdisabled-optimization
> -Wstack-protector
> -Wbuiltin-macro-redefined
> -Wmudflap
> -Wpacked-bitfield-compat
> -Wsync-nand
> -Wattributes
> -Wcoverage-mismatch
> -Wmultichar
> -Wunused-macros
> -Wno-missing-field-initializers
> -Wno-missing-field-initializers
> -Wno-sign-compare
> -Wno-type-limits
> -Wno-switch
> -Wno-unused-parameter
> -Werror




reply via email to

[Prev in Thread] Current Thread [Next in Thread]