Add AllocateOptions to QArrayData
authorJoão Abecasis <joao.abecasis@nokia.com>
Tue, 22 Nov 2011 16:28:14 +0000 (17:28 +0100)
committerQt by Nokia <qt-info@nokia.com>
Mon, 9 Jan 2012 16:19:30 +0000 (17:19 +0100)
commitf1e48d48fd58b28b1dc18652af3fc74da5e112fd
tree41f355093999ea8dabf9c196afb4e0ad275ce547
parentd91b4f0b13926a0861d7e172f14437d20d06332e
Add AllocateOptions to QArrayData

This approach is better for future ABI evolution than using individual
bool parameters. QArrayData now also offers to calculate allocate
options for typical detach and clone operations: the CapacityReserved
flag is preserved, while cloning resets the Unsharable state.

Change-Id: I256e135adcf27a52a5c7d6130069c35c8b946bc3
Reviewed-by: João Abecasis <joao.abecasis@nokia.com>
src/corelib/tools/qarraydata.cpp
src/corelib/tools/qarraydata.h
src/corelib/tools/qarraydatapointer.h
tests/auto/corelib/tools/qarraydata/simplevector.h
tests/auto/corelib/tools/qarraydata/tst_qarraydata.cpp