[Development] Deprecation warnings are enabled

Olivier Goffart olivier at woboq.com
Mon Apr 30 23:47:58 CEST 2012


On Monday 30 April 2012 21:34:45 lorn.potter at nokia.com wrote:
> On 01/05/2012, at 12:07 AM, ext Thiago Macieira wrote:
> > On sexta-feira, 27 de abril de 2012 23.02.58, Thiago Macieira wrote:
> >> Just a notice to all devs:
> >> 
> >> Since 0df1c9f1fa04c06d6105de3f312c6c752a58ad70 integrated on Wednesday,
> >> all
> >> Qt modules have deprecation warnings enabled now. That means that when
> >> you
> >> build your module, you'll get warnings about your using of deprecated
> >> classes or function.
> >> 
> >> You should not ignore them. You should use the replacement functions /
> >> classes.
> > 
> > The next step is to disable the deprecated methods. The change will be:
> > 	https://codereview.qt-project.org/#change,24890
> > 
> > I will remove the WIP and stage that change in about two or three weeks,
> > but before the beta.
> 
> Any way the warnings could include some kind of hint to what _should_ be
> used instead?

That would be quite difficult.

Thinking about it, i would maybe do it like this:

QT_DEPRECATED void setOldString(const QString &oldString, 
                     class use_setNewString_instead *=0);

(But this trick cannot be used in a minor release as it changes the function 
signature)

I donn't think it is worth it.
The best way it to go have a look at the docs.


> And docs should include replacement info on any depreciated function.

Yes they "should" :-)
In general they do. If they don't feel free to fix it.



More information about the Development mailing list