TIL: Typed do in Swift

TL;DR: Swift has do throws(MyError) . It&#x27;s helpful. This is one of those "I can&#x27;t believe I had missed that" things. I&#x27;ve been pretty enthusiastic about adopting typed throws in Swift. If you need to process certain kinds of errors, it just makes sense to me. However, it was always a bit painful. You have this: do { &#x2F;&#x2F; throwing code here } catch { &#x2F;&#x2F; error is…