KDE/kdepimlibs/syndication

Frank Osterfeld frank at kdab.net
Tue May 1 11:13:02 BST 2007


On Tuesday 01 May 2007 11:10:37 Peter Kümmel wrote:
> Christian Ehrlicher wrote:
> > Frank Osterfeld schrieb:
> >> SVN commit 659695 by osterfeld:
> >>
> >> port to boost::shared_ptr
> >
> > Do we really need boost here :(
> > Another dependecy in the long list...
> >
> > Christian
>
> When it is only the smart pointer, then
> I think it should be replaced with something else.
> Aren't there already smart pointers in kdelibs?

Yes, KSharedPtr, which requires the shared class to inherit from KShared, 
which is ugly and unacceptable in many use cases (For example, a class that 
inherits KShared can't be used by value any more). Frerich suggested a 
replacement a while back, which was rejected because it caused problems with 
the existing code in kdelibs relying on the behaviour of the old KSharedPtr ( 
a problem neither akonadi nor libsyndication have). I used Frerich's version 
until now by copying it into libsyndication - and I already had to patch it 
to make it work with Ms VS compilers when the shared type is an abstract 
class. So having every KDE lib and app shipping their own sharedptr can't be 
the solution - given that there is a well-tested version in boost becoming 
part of the standard soon.
(Note that also kdepim/akonadi uses boost::shared_ptr, libsyndication is 
merely following here (because I think it makes sense to have a widely used 
and tested shared_ptr implementation).

-- 
Frank Osterfeld -- frank at kdab.net
Klarälvdalens Datakonsult AB, Platform-independent software solutions
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
URL: <http://mail.kde.org/pipermail/kde-core-devel/attachments/20070501/0c154aec/attachment.sig>


More information about the kde-core-devel mailing list