[swift-evolution] Pre-proposal: CaseEnumerable protocol (derived collection of enum cases)
Jacob Bandes-Storch
jtbandes at gmail.com
Tue Jan 19 12:36:45 CST 2016
Yes: ErrorType.
On Tue, Jan 19, 2016 at 10:21 AM, Sune Foldager <cyano at me.com> wrote:
>
> On 18 Jan 2016, at 00:44, Jacob Bandes-Storch via swift-evolution <
> swift-evolution at swift.org> wrote:
>
> Introduce a CaseEnumerable protocol. Conforming to CaseEnumerable will
> automagically derive a static var cases, whose type is a CollectionType
> of all the enum's values.
>
>
> Hm, I don’t think I like that. Are there other examples of magic protocols
> in Swift?
>
> -Sune
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.swift.org/pipermail/swift-evolution/attachments/20160119/75db41f3/attachment.html>
More information about the swift-evolution
mailing list