[Development] Question about QCoreApplicationData::*_libpaths

Kevin Kofler kevin.kofler at chello.at
Wed Jan 20 05:16:49 CET 2016


Marc Mutz wrote:

> On Saturday 16 January 2016 02:40:02 Bubke Marco wrote:
>>  I would prefer it we had a CoW wrapper around std vector.
>> Best of both worlds.
> 
> aka std::shared_ptr<std::vector<...>>

std::shared_ptr is NOT CoW = implicitly shared, it is explicitly shared. 
There is no detaching, so where do you see a copy on write?

A CoW wrapper around std::vector needs to at least be a 
QSharedDataPointer<VectorData<T> > where class VectorData<T> : public 
QSharedData, public std::vector<T>.

        Kevin Kofler




More information about the Development mailing list