How to handle error propagated to the calling function in Swift?

We handle errors propagated to the calling function from a catch clause using do-catch statements.

 

Any errors that are nor mentioned in error protocol we defined, the error is propagated to the calling function and handled by a simple catch clause.

Leave a Reply