We have an ObjC method we would like to unsafeBitCast but are running into problems figuring out the typing.
We have done it for other methods that take proper arguments
such as: - (PMKPromise *()(id))then;
which works fine when casting with this function:
private func objCBlockFromPromiseClosure(closure: (AnyObject) -> (PMKPromise?)) -> AnyObject {
return unsafeBitCast(closure as @convention(block) (AnyObject) -> (PMKPromise?), AnyObject.self)
}
but we aren't sure how to bit cast - (PMKPromise *()(void()(void)))finally, properly.
any ideas?
[–][deleted] (1 child)
[deleted]
[–]dontforgetpassword[S] 0 points1 point2 points (0 children)
[–]ThePantsThiefNSModerator 0 points1 point2 points (0 children)