[swift-users] Memory management without ARC?
matthias at objecthub.net
Sat Jan 30 12:59:13 CST 2016
> Doing your own GC is probably the best you can do today. You can manually retain and release references to Swift classes using the Unmanaged<T> type, which might help interoperate Swift ARC objects with your GC.
I found some references to Unmanaged<T> on the web as well, but couldn't figure out how to use it with Swift classes. It seems like Unmanaged<T> exists for interfacing with objects that are not created/managed via the Swift runtime. But as soon as I instantiate a Swift class, it uses the Swift runtime. Is there a way to create an object of a Swift class such that it's not managed by the Swift runtime?
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the swift-users