<html><head><meta http-equiv="Content-Type" content="text/html charset=utf-8"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class=""><div class="">I agree that this is a necessity, but mixing type requirements with a construct limitation should not be the way forward. To take your example I would try to separate those informations by doing:</div><div class=""><br class=""></div><div class="">typealias class T: FooType</div><div class=""><br class=""></div><div class="">I myself don’t have a perfect solution for the case of multiple protocol conformance except for creating a wrapper protocol that incorporates all required protocols</div><div class=""><br class=""></div><br class=""><div><blockquote type="cite" class=""><div class="">On Dec 7, 2015, at 6:02 PM, Stephen Celis <<a href="mailto:stephen.celis@gmail.com" class="">stephen.celis@gmail.com</a>> wrote:</div><br class="Apple-interchange-newline"><div class=""><div dir="ltr" class="">Ah, given what Joe mentioned (`typealias T: class`, `<T: class>`), it actually makes a lot of sense given `protocol<…>`.<div class=""><div class=""><br class=""></div><div class="">Stephen</div></div></div><div class="gmail_extra"><br class=""><div class="gmail_quote">On Mon, Dec 7, 2015 at 11:58 AM, Felix Gabel <span dir="ltr" class=""><<a href="mailto:felix.gabel@me.com" target="_blank" class="">felix.gabel@me.com</a>></span> wrote:<br class=""><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div style="word-wrap:break-word" class=""><div class="">Every time you want to implement Delegates it will be a requirement that your delegate property is a weak optional that conforms to that protocol. This already implicitly enforces that the protocol is a class protocol. I personally don’t like this implicit notion and would personally prefer a protocol explicitly declared as a class protocol. </div><div class=""><br class=""></div><div class="">Therefore +1 from my side for:</div><div class=""><br class=""></div><div class="">class protocol Foo {}</div><div class="">class protocol Bar : Foo {}</div><div class=""><br class=""></div><br class=""><div class=""><blockquote type="cite" class=""><div class=""><div class="h5"><div class="">On Dec 7, 2015, at 5:51 PM, Stephen Celis via swift-evolution <<a href="mailto:swift-evolution@swift.org" target="_blank" class="">swift-evolution@swift.org</a>> wrote:</div><br class=""></div></div><div class=""><div class=""><div class="h5"><div dir="ltr" class="">Do others find themselves implementing class-only protocols often? They seem to be the exception, rather than the rule, to me.<div class=""><br class=""></div><div class="">Stephen</div><div class="gmail_extra"><br class=""><div class="gmail_quote">On Mon, Dec 7, 2015 at 11:32 AM, Sean Heber via swift-evolution <span dir="ltr" class=""><<a href="mailto:swift-evolution@swift.org" target="_blank" class="">swift-evolution@swift.org</a>></span> wrote:<br class=""><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">I found this odd, too. I don’t know what kind of parsing ramifications this might have, but I like the idea. I suppose one downside is that it makes protocols for classes seem somehow special or different from other protocols - but then again, they kind of are!<br class="">
<br class="">
l8r<br class="">
Sean<br class="">
<div class=""><div class=""><br class="">
<br class="">
> On Dec 7, 2015, at 10:00 AM, Matthew Cheok via swift-evolution <<a href="mailto:swift-evolution@swift.org" target="_blank" class="">swift-evolution@swift.org</a>> wrote:<br class="">
><br class="">
> Currently, we declare class protocols with the following syntax:<br class="">
><br class="">
> protocol TestProtocol: class, OtherProtocol {}<br class="">
><br class="">
> This is odd for a few reasons:<br class="">
> 1) The keyword class exists in the middle of the declaration<br class="">
> 2) The keyword class follows the colon and looks a lot like inheritance<br class="">
> 3) The keyword class occupies a somewhat arbitrary first position after the colon (otherwise we have an error)<br class="">
><br class="">
> We also have another use of the class keyword as a modifier when declaring class methods:<br class="">
><br class="">
> class func doSomething() {}<br class="">
><br class="">
> I’m suggesting a change of syntax that rectifies the above issues:<br class="">
><br class="">
> class protocol TestProtocol: OtherProtocol {}<br class="">
><br class="">
> Would love to hear other thoughts on this.<br class="">
><br class="">
> - Matthew<br class="">
><br class="">
> _______________________________________________<br class="">
> swift-evolution mailing list<br class="">
> <a href="mailto:swift-evolution@swift.org" target="_blank" class="">swift-evolution@swift.org</a><br class="">
> <a href="https://lists.swift.org/mailman/listinfo/swift-evolution" rel="noreferrer" target="_blank" class="">https://lists.swift.org/mailman/listinfo/swift-evolution</a><br class="">
<br class="">
_______________________________________________<br class="">
swift-evolution mailing list<br class="">
<a href="mailto:swift-evolution@swift.org" target="_blank" class="">swift-evolution@swift.org</a><br class="">
<a href="https://lists.swift.org/mailman/listinfo/swift-evolution" rel="noreferrer" target="_blank" class="">https://lists.swift.org/mailman/listinfo/swift-evolution</a><br class="">
</div></div></blockquote></div><br class=""></div></div>
</div></div><img alt="" width="1" height="1" border="0" style="min-height:1px!important;width:1px!important;border-width:0!important;margin-top:0!important;margin-bottom:0!important;margin-right:0!important;margin-left:0!important;padding-top:0!important;padding-bottom:0!important;padding-right:0!important;padding-left:0!important" class="">
_______________________________________________<span class=""><br class="">swift-evolution mailing list<br class=""><a href="mailto:swift-evolution@swift.org" target="_blank" class="">swift-evolution@swift.org</a><br class=""><a href="https://lists.swift.org/mailman/listinfo/swift-evolution" target="_blank" class="">https://lists.swift.org/mailman/listinfo/swift-evolution</a><br class=""></span></div></blockquote></div><br class=""></div></blockquote></div><br class=""></div>
</div></blockquote></div><br class=""></body></html>