You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The initial conversion to Swift retained the implementation of making and throwing NSErrors, which are unwieldy in Swift. Additionally, the specific errors must be parsed from the localizedDescription regardless of language, which is even more unwieldy. The Codable enhancements introduce DecodingError and EncodingError as appropriate, but are limited to contexts where encoders or decoders are "in flight" (the extensions). Lastly, some APIs do not propagate errors, such as save().
The use of DecodingError and EncodingError should be extended where appropriate
Remaining usage of NSError should be replaced with a GarageError enumeration
Ensure that more errors are propagated in APIs such as save(), by reducing or eliminating their catch blocks, and replacing print statements with throw.
The text was updated successfully, but these errors were encountered:
The initial conversion to Swift retained the implementation of making and throwing NSErrors, which are unwieldy in Swift. Additionally, the specific errors must be parsed from the localizedDescription regardless of language, which is even more unwieldy. The Codable enhancements introduce DecodingError and EncodingError as appropriate, but are limited to contexts where encoders or decoders are "in flight" (the extensions). Lastly, some APIs do not propagate errors, such as save().
The text was updated successfully, but these errors were encountered: