Definition of done - warning

David Faure faure at kde.org
Fri Aug 10 21:06:12 UTC 2012


On Tuesday 07 August 2012 19:37:59 Albert Astals Cid wrote:
> El Dimarts, 7 d'agost de 2012, a les 16:56:01, Kevin Ottens va escriure:
> > Hello,
> > 
> > Looks like it got overlooked. ;-)
> > 
> > On Saturday 07 July 2012 12:20:01 Benjamin Port wrote:
> > > Currently when we build kdelibs there are lots of warnings. That's why I
> > > suggest to add a remove all warnings in the definition of done.
> > > 
> > > But we can't remove all warnings, indeed some warnings come from moc
> > > file
> > > (deprecated slots) and from unit test where we want to test the behavior
> > > of
> > > deprecated method.
> > > 
> > > For the first one I don't have any idea to manage that (and I think
> > > there
> > > is no solution)
> > > For unit test we can add to gcc the -Wno-deprecated-declarations option.
> > > Perhaps we can do that by adding a test macro defined in ecm.
> > > 
> > > So I suggest to have the following definition of done:
> > > "Remove all warning except in moc files (deprecated slot)"
> > > 
> > > Yes that is lot of work but I think if we manage to do that, in the
> > > future
> > > we can easely continu to have a warningless code.
> > 
> > I generally agree with that proposal. I would completely welcome such a
> > 
> > move, that said it raises a couple of points:
> >  * If we make such a change, the situation regarding the unit tests should
> > 
> > be investigated, and if a macro is needed in ECM it has to be in place
> > before the change for the definition of done is applied;
> > 
> >  * It generally raises the follow up question of the level of warning we
> > 
> > want to force, right now by default I got -Wall + some extra warnings[*]
> > is
> > it enforced for everyone right now? How far to we want to go? What about -
> > pedantic?
> > 
> >  * And the extra question, once we got there, do we want -Werror?
> > 
> > (apparently not doable because of deprecated slots though?)
> > 
> > I remember David and Laurent pushing the bar quite a bit regarding the
> > warnings but then they gave up because people kept not caring enough about
> > those... -Werror by default would help there I think. :-)
> 
> -Werror is the worst thing ever, i've been forced to use it at work for some
> projects and it is a hideous thing that breaks the compilation half of the
> time while you are developing just because you left an unused variable
> somethwere, please don't force it on us.

Yep, I've had too many issue with -Werror breaking compilation for people with 
a newer version of gcc than me, which suddenly got better at detecting a given 
issue.

I'm strongly against -Werror by default. But turning it on locally is of 
course the best way to implement what we're talking about here: cleaning a 
framework of all its warnings.

-- 
David Faure, faure at kde.org, http://www.davidfaure.fr
Sponsored by Nokia to work on KDE, incl. KDE Frameworks 5



More information about the Kde-frameworks-devel mailing list