Avatar
PはProtocolにしたいけど、assoctypeはもう型をきめちゃいたいときに有効
11:08 AM
昔書きたくて書けないなーってことが何度かある
11:10 AM
なんかすっきりかけそう protocol Request { associatedtype Response func request() } protocol StringRequest: Request where Self.Response == String { func decode() }