Hello all,
We are proceeding to update all of our Swift code to Swift 3 now and had a few
questions about the proper way to implement Errors. We need these entities to
be available in Objective-C and they are actively being used in Swift classes
marked as @objc.
I read:
https://github.com/app
ope this is closer to the correct way to implement this.
Thanks!
Ronak
> On Sep 29, 2016, at 1:17 PM, Ronak via swift-users
> wrote:
>
> Hello all,
>
> We are proceeding to update all of our Swift code to Swift 3 now and had a
> few questions about the proper way to impl
return __MyErrorCode.two.rawValue
> case .three:
> return __MyErrorCode.three.rawValue
> }
> }
>
> var errorUserInfo: [String: Any] {
> var userInfo = [String: Any]()
> if case let .one(string) = self {
> u
else if case let .three(info) = self {
userInfo = info
}
return userInfo
}
}
Thanks
Ronak
> On Sep 29, 2016, at 5:46 PM, Ronak via swift-users
> wrote:
>
> Ahh..thanks for the reply Zach. I didn’t actually see your reply until now.
>
> I’ll see how I can adjus
ann wrote:
>
> Have you tried explicitly casting the value to NSError when you pass it to
> Objective-C? I think it should work then.
>
>let myError: MyError = ...
>myObjCFunc(myError as NSError)
>
> On 02/03/2017 17:29, Ronak via swift-users wrote:
>> Hi e