[swift-evolution] RFC: Proposed rewrite of Unmanaged<T>

Janosch Hildebrand jnosh at jnosh.com
Tue Dec 29 15:10:05 CST 2015


I like "transfer" but I think this would be mostly helpful to people familiar with manual ref. counting in Obj-C.
It's probably just as confusing to others and the visual similarity could be confusing as well (like with `Unmanaged`).

But I also wouldn't be opposed to these if they were selected...


> On 20 Dec 2015, at 06:56, Félix Cloutier via swift-evolution <swift-evolution at swift.org> wrote:
> 
> There's still the "release" issue (std::unique_ptr::release versus -[NSObject release]), but "transfer" seems like a good word to me. What about "transferByRetaining" and "transferWithoutRetaining"?
> 
> Félix
> 
>> Le 20 déc. 2015 à 00:01:22, Nevin Brackett-Rozinsky via swift-evolution <swift-evolution at swift.org <mailto:swift-evolution at swift.org>> a écrit :
>> 
>> Floating an idea here—not sure if it’s even in the right ballpark, and I’m certainly not tied to the specific wording, but what about something along the lines of:
>> 
>> .transferByReleasing()
>> .transferWithoutReleasing()      // or perhaps just .transfer()
>> 
>> Or the slightly-more-verbose:
>> 
>> .transferObjectByReleasingReference()
>> .transferObjectWithoutReleasingReference()        // or .transferObject()
>> 
>> Nevin

- Janosch

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.swift.org/pipermail/swift-evolution/attachments/20151229/3023befa/attachment.html>


More information about the swift-evolution mailing list