Avatar
We all love enums! Every time when I am adding Result to project, I wonder why it is not included in stdlib. enum Result { case success(T) case failure(Error) public init( value: T) { self = .success(value) } public init( error: Error) { self = .failure(error) } } This is very powerful type while using it with Swift pattern matching operators like switch or if-case .
10:22 AM
繰り返す・・・