eonist / my-swift-projects

An overview of my most relevant open-source projects on GitHub
264 stars 22 forks source link

a few cleanups #5

Closed paperlib closed 7 years ago

paperlib commented 7 years ago

Remove the conversion between Unsafe/Unmanaged in favor of the more direct and simpler Unmanaged.passUnretained self assignment to context.info.

(explanation: Swift 3 allows us to bypass the pingpong between Unsafe/Opaque/Unmanaged and back again, so we can use Unmanaged directly here - see this https://github.com/apple/swift-evolution/blob/master/proposals/0017-convert-unmanaged-to-use-unsafepointer.md for the details.)

Getting rid of unsafeBitCast.

eonist commented 7 years ago

I will check it tonight. Pingpong 😆 Well said.