[Development] Making QScopedPointer scoped (again)

Janusz Lewandowski lew21 at enves.pl
Wed Sep 4 23:35:07 CEST 2013


On Wed, 4 Sep 2013 19:48:53 +0000 Knoll Lars <Lars.Knoll at digia.com> wrote

> So then there are basically two options:
> 
> 1. We extend QScopedPointer and live with the fact that the name is not
> perfect, as scoping can be broken explicitly.
> 2. We add a QUniquePointer that has pretty much the functionality that we
> now have in QScopedPointer, and we revert the change that added moving to
> QScopedPointer
> 3. We revert the patch, and hope that C++11 spreads fast enough so that
> people will start using unique_ptr instead. Then we deprecate
> QScopedPointer.

You also can typedef QScopedPointer QUniquePointer; and deprecate the former
name.

Cheers,
Janusz





More information about the Development mailing list