Subject: bug#23640: 25.1.50; Getting rid of compiler warnings

From: Ken Brown <[email-masked]>
Date: Sat, 28 May 2016 17:47:53 -0400

On 5/28/2016 2:57 PM, Eli Zaretskii wrote:
>> From: Ken Brown <[email-masked]>
>> Date: Sat, 28 May 2016 14:40:36 -0400
>>
>> Building master on Cygwin with gcc-5.3.0 yields many "control reaches
>> end of non-void function" warnings.  What's the best way to get rid of
>> these?  Should I add return statements that will never be reached, like
>> this?
>>
>> --- a/src/frame.c
>> +++ b/src/frame.c
>> @@ -263,6 +263,8 @@ See also `frame-live-p'.  */)
>>         return Qns;
>>       default:
>>         emacs_abort ();
>> +      /* Pacify compiler.  */
>> +      return Qnil;
>>       }
>>   }
>
> emacs_abort is declared with _Noreturn, so how come GCC doesn't shut
> up about "unreachable" code?

It looks like the problem is the definition of _Noreturn as a macro in 
config.h.  I'll have to figure out what's going on.

Ken