[llvm-commits] [llvm] r157546 - /llvm/trunk/include/llvm/ADT/IntrusiveRefCntPtr.h

Sebastian Redl sebastian.redl at getdesigned.at
Tue May 29 00:34:19 PDT 2012


On 29.05.2012 09:26, Sebastian Redl wrote:
> On 29.05.2012 01:28, Richard Smith wrote:
>> How about replacing all five operator= overloads (duplicating the work
>> of the constructors) and the 'replace' member function with just:
>>
>> IntrusiveRefCntPtr&  operator=(IntrusiveRefCntPtr O) {
>>    swap(O);
>>    return *this;
>> }
>>
> That would incur an additional AddRef/Release for the move case. Not
> sure if that is relevant.
>
Never mind, I'm stupid.

Sebastian



More information about the llvm-commits mailing list