On Tuesday 27 October 2009 19:20:46 Albert Astals Cid wrote:
> A Dimarts, 27 d'octubre de 2009, Olivier Goffart va escriure:
> > On Monday 26 October 2009 19:36:36 Albert Astals Cid wrote:
> > > qvariant.h has
> > >
> > > struct Private
> > > {
> > > ...
> > >         uint type : 30;
> > > ...
> > > }
> > >
> > > ...
> > >
> > > const int type = qMetaTypeId<T>(reinterpret_cast<T *>(0));
> > > QVariant::Private &d = v.data_ptr();
> > > if (v.isDetached() && (type <= int(QVariant::Char) || type == d.type))
> > >
> > > In the if it is comparing type (an int) with d.type (an uint) and this
> > > is generating warning reports, can it be fixed?
> >
> > Eh, you are not supposed to use private data.
> >
> > So no, there is no reason we change that.  don't use d.type,  use
> > QVariant::userType instead.
> 
> I don't, it's just my compiler that warns me of a comparison problem in
>  your code.
> 
> Ah, ok, maybe it was not clear enough, the 3 lines snippet is Qt code from
> qVariantSetValue
> 
> Albert

This is fixed with commit 51f1d68addd2351
(it might take few days before being available in gitorious)
_______________________________________________
Qt4-preview-feedback mailing list
[email protected]
http://lists.trolltech.com/mailman/listinfo/qt4-preview-feedback

Reply via email to