[Development] QSharedPointer - Enable shared from this

Thiago Macieira thiago.macieira at intel.com
Thu Oct 31 16:24:08 CET 2013


On quinta-feira, 31 de outubro de 2013 15:57:13, Cristian Pallarés wrote:
> Hi folks,
> 
> https://codereview.qt-project.org/60346
> 
> I've waited quite a bit for this feature. C++11 already ships this
> implementation, which makes std::shared_ptr very powerful, but the review
> process for the Qt implementation looks frozen.
> 
> QSharedPointer is limited to me for that missing feature. For example, I
> want to make a tree class that uses shared pointers. Without "shared from
> this" I have to write very ugly things such privatizing the class
> constructors and implementing a public static "constructor" that creates
> the shared pointer for me and stores a weak pointer to the class itself.
> 
> I'm wondering if could someone take a look at that.

That would be me. Sorry, I haven't looked at it in a while...
The way I work is that I ignore the topmost reviews in my dashboard because 
they're old and useless. Looks like this one shouldn't have been ignored.

-- 
Thiago Macieira - thiago.macieira (AT) intel.com
  Software Architect - Intel Open Source Technology Center
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 190 bytes
Desc: This is a digitally signed message part.
URL: <http://lists.qt-project.org/pipermail/development/attachments/20131031/a482e3fe/attachment.sig>


More information about the Development mailing list