https://gcc.gnu.org/bugzilla/show_bug.cgi?id=67629

Eric Gallager <egallager at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |NEW
   Last reconfirmed|                            |2017-07-28
                 CC|                            |egallager at gcc dot gnu.org
     Ever confirmed|0                           |1

--- Comment #3 from Eric Gallager <egallager at gcc dot gnu.org> ---
(In reply to Martin Sebor from comment #0)
> While testing Marek's patch for PR 64249 I noticed that both gcc and g++
> incorrectly issue a -Wreturn-type warning for the following snippet:
> 
> $ cat u.c && xgcc -Wreturn-type -c u.c
> int foo (_Bool a) {
>     if (a) return 0;
>     else if (!a) return 1;
> }
> u.c: In function ‘foo’:
> u.c:4:1: warning: control reaches end of non-void function [-Wreturn-type]
>  }
>  ^

Confirmed.

Reply via email to