[webkit-dev] Can we disable "control reaches end of non-void function" warning on Qt?

Filip Pizlo fpizlo at apple.com
Thu Sep 12 20:46:28 PDT 2013


On Sep 12, 2013, at 7:54 PM, Ryosuke Niwa <rniwa at webkit.org> wrote:

> Hm... it appears that I was wrong about this.  It appears that this is the intended feature in gcc:
> http://gcc.gnu.org/bugzilla/show_bug.cgi?id=28236

Yuck!  Madness!

> 
> Regardless, I don't think we should have this warning enabled. We're generating some unused code everywhere :(

:-(

Yes, we could say that the warning is disabled in gcc and enabled in clang.  I'm not sure that's fair, though.  We do all sorts of strange things to silence clang sometimes; it's only fair that once in a while we do things to silence gcc.  So unless we say that WebKit should only be developed on clang, we should probably agree to sometimes silence gcc's peculiarities.

-Filip


> 
> - R. Niwa
> 
> 
> On Thu, Sep 12, 2013 at 5:15 PM, Allan Sandfeld Jensen <kde at carewolf.com> wrote:
> On Friday 13 September 2013, Benjamin Poulain wrote:
> > On 9/12/13 4:48 PM, Ryosuke Niwa wrote:
> > > On Thu, Sep 12, 2013 at 4:45 PM, Allan Sandfeld Jensen
> > >
> > > <kde at carewolf.com <mailto:kde at carewolf.com>> wrote:
> > >     Don't worry we are still here, just in fewer numbers, and with
> > >     fewer things to
> > >     support.
> > >
> > >     I would prefer to keep the warning, it is quite useful at times,
> > >     and when it
> > >     isn't you just add a default case with an ASSERT_NOT_REACHED()
> > >
> > > And that's an added maintenance cost everyone has to pay.
> > >
> > > Given that other ports such as Mac & GTK+ have this warning enabled
> > > and we have reliable EWS bots, I don't see why we want to keep this
> > > warning on ports that use old versions of gcc that force us to add
> > > useless code.
> >
> > I agree with you on this, I had the problem several times.
> >
> > I think the best would be to update the Qt bots. If that cannot be done,
> > it would be best to disable the warning until the bots can be upgraded.
> >
> Do we know what GCC versions are bad, or at least at what point they become
> good enough on this warning? (we tend to get more warnings not fewer with gcc
> 4.8).
> 
> `Allan
> 
> _______________________________________________
> webkit-dev mailing list
> webkit-dev at lists.webkit.org
> https://lists.webkit.org/mailman/listinfo/webkit-dev

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.webkit.org/pipermail/webkit-dev/attachments/20130912/1afc52f5/attachment.html>


More information about the webkit-dev mailing list