<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="">You are right, I was unaware of “inline” protocol composition. Nice! <div class=""><br class=""></div><div class=""><div class="">But I didn’t found that you can specify <b class="">class…</b></div></div><div class=""><br class=""></div><div class="">Although I’d prefer just to list required protocols spaceseparated. </div><div class=""><br class=""></div><div class="">I also think that it has to be explained as normal/basic option when explaining method declaration (not in protocols definition chapter).<div class=""><br class=""></div><div class=""><br class=""></div><div class="">Thanks!</div><div class=""><br class=""></div><div class=""><br class=""></div><div class=""><br class=""></div><div class=""><br class=""><div><blockquote type="cite" class=""><div class="">El 8 des 2015, a les 17:55, Stephen Celis <<a href="mailto:stephen.celis@gmail.com" class="">stephen.celis@gmail.com</a>> va escriure:</div><br class="Apple-interchange-newline"><div class=""><div dir="ltr" class="">On Tue, Dec 8, 2015 at 11:52 AM, Daniel Valls Estella 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=""><div class="gmail_extra"><div class="gmail_quote"><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="">Just to clarify.<div class=""><br class=""></div><div class="">I think maybe it’s better to move away class constrain from protocol definitions </div><div class="">and enable such type of restriction when requesting elements alongside with type/protocol conformance requirements.</div><div class=""><br class=""></div><div class=""><div style="word-wrap:break-word" class=""><div class=""><font face="Courier New" class="">func doSomething(localvar: MyProtocol class)</font></div></div></div></div></blockquote><div class=""><br class=""></div><div class="">Doesn't the following work? <br class=""></div><div class=""><br class=""></div><div class=""> func doSomething(localvar: protocol<MyProtocol, class>)</div><div class=""><br class=""></div><div class="">You could, of course, use a typealias or protocol inheritance to avoid "protocol<...>". </div></div></div></div>
</div></blockquote></div><br class=""></div></div></body></html>