[Interest] What's the recommended way to put QObjects in smart pointers?
Thiago Macieira
thiago.macieira at intel.com
Thu May 5 06:19:42 CEST 2016
On quinta-feira, 5 de maio de 2016 04:24:48 PDT Nikos Chantziaras wrote:
> > So what are you requirements? Do you want to a container that does delete
> > the object it has, unless the parent has already deleted it?
>
> Well, basically what I want is not having even a single 'new' or
> 'delete' anywhere in my code. I already achieved that with all my non-Qt
> projects.
If you don't want to use new or delete, use stack-based objects and only
create children objects as members. That is, what Nye suggested.
--
Thiago Macieira - thiago.macieira (AT) intel.com
Software Architect - Intel Open Source Technology Center
More information about the Interest
mailing list