Use of Boost library classes in kdecore?

David Jarvie lists at astrojar.org.uk
Sat Jul 7 11:38:28 BST 2007


On Saturday 07 July 2007 10:01:19 Thiago Macieira wrote:
> David Jarvie wrote:
> >To successfully use reference counting, you need to do it as
> > automatically as possible. KShared (alias QSharedData) doesn't do it
> > itself - it's done by KSharedPtr (or QSharedDataPointer, which provides
> > automatic cloning when non-const methods are called, which is not
> > appropriate for KTimeZone). shared_ptr in the Boost library does a
> > similar thing to KSharedPtr, but provides other necessary functionality
> > as well.
>
> QExplicitlySharedDataPointer
>
> We need to get the Trolls to document that one and add the missing
> detach() method.

QExplicitlySharedDataPointer would be suitable to use with a single class, but 
it still doesn't cope with implicit conversions between base and derived 
classes.

-- 
David Jarvie.
KAlarm author and maintainer.
http://www.astrojar.org.uk/kalarm




More information about the kde-core-devel mailing list