<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=""><br class=""><div><blockquote type="cite" class=""><div class="">On May 27, 2016, at 7:20 AM, Thorsten Seitz via swift-evolution &lt;<a href="mailto:swift-evolution@swift.org" class="">swift-evolution@swift.org</a>&gt; wrote:</div><br class="Apple-interchange-newline"><div class=""><meta http-equiv="Content-Type" content="text/html charset=utf-8" class=""><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class="">From the point of view of the type system `P &amp; Q` is an anonymous supertype of `P` and `Q`.<div class="">This would be just the same if the syntax was `Any&lt;P, Q&gt;`. I don’t see a semantic difference here.<div class=""><br class=""></div><div class="">Whether that is a "container“ or not seems to be an implementation detail to me but should have nothing to do with the type system.</div><div class="">In what way should it be "lossy“?</div><div class=""><br class=""></div><div class="">Am I missing something?</div></div></div></div></blockquote><div><br class=""></div><div>I was a bit confused as well and had to read this several times. &nbsp;I think this is talking about a syntactic “container” - i.e. brackets of some kind (as opposed to a “free floating” syntax). &nbsp;I don’t think it is talking about a semantic difference of any kind. &nbsp;But maybe I am still confused an not understanding what was intended...</div><br class=""><blockquote type="cite" class=""><div class=""><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class=""><div class=""><div class=""><br class=""></div><div class="">-Thorsten</div><div class=""><br class=""></div><div class=""><br class=""><div class=""><blockquote type="cite" class=""><div class="">Am 27.05.2016 um 12:30 schrieb L. Mihalkovic &lt;<a href="mailto:laurent.mihalkovic@gmail.com" class="">laurent.mihalkovic@gmail.com</a>&gt;:</div><br class="Apple-interchange-newline"><div class=""><meta http-equiv="content-type" content="text/html; charset=utf-8" class=""><div dir="auto" class=""><div class="">It seem to me we are debating the <i class="">how</i> of a <i class=""><b class="">what</b></i> that has not been defined. The root question behind all these alternatives seems to be to decide if the existential-ness should be carried by a 'container' that is then refined internally, or derived from the presence of the <i class="">free-floating</i> refinements. This is the question that splits the possible syntaxes into these 2 groups:</div><div class=""><br class=""></div><div class="">Any&lt;&gt; Any[]</div><div class="">Type&lt;&gt; Type&lt;&gt;&nbsp;</div><div class="">Existential&lt;&gt;</div><div class=""><br class=""></div><div class="">and the (these are all straw man representations that should not limit the thinking)</div><div class=""><br class=""></div><div class="">P &amp; Q</div><div class="">@P and @Q</div><div class="">is P , Q</div><div class="">P &amp; Q typed</div><div class=""><br class=""></div><div class="">If the answer is to use a 'container' then the next question is to see its relationship to the other existing containers: is it the result of a transformation, is it a superset, or a super type; it is obviously lossy, but not entirely if the solution follows in some of Brent's past suggestion to make some existential types instantiate-able (which opens a very similar problem to what java faced for several years when trying to identify a universal collection literal syntax).</div><div class="">That will narrow down the field of possible matches... until one syntax emerges as conveying the meaning that is reflected by the answers to each question.</div><div class=""><br class="">On May 27, 2016, at 10:55 AM, Thorsten Seitz via swift-evolution &lt;<a href="mailto:swift-evolution@swift.org" class="">swift-evolution@swift.org</a>&gt; wrote:<br class=""><br class=""></div><blockquote type="cite" class=""><div class=""><meta http-equiv="Content-Type" content="text/html charset=utf-8" class="">We could just write<div class=""><br class=""></div><div class="">let x: P &amp; Q</div><div class="">instead of</div><div class="">let x: Any&lt;P, Q&gt;</div><div class=""><br class=""></div><div class="">let x: Collection where .Element: P</div><div class="">instead of</div><div class="">let x: Any&lt;Collection where .Element: P&gt;</div><div class=""><br class=""></div><div class="">let x: P &amp; Q where P.T == Q.T</div><div class="">instead of</div><div class="">let x: Any&lt;P, Q where P.T == Q.T&gt;</div><div class=""><br class=""></div><div class="">let x: P &amp; Q &amp; R</div><div class="">instead of</div><div class="">let x: Any&lt;P, Q, R&gt;</div><div class=""><br class=""></div><div class="">let x: Collection</div><div class="">instead of</div><div class="">let x: Any&lt;Collection&gt;</div><div class=""><br class=""></div><div class=""><br class=""></div><div class="">This would avoid the confusion of Any&lt;T1, T2&gt; being something completely different than a generic type (i.e. order of T1, T2 does not matter whereas for generic types it is essential).</div><div class=""><br class=""></div><div class=""><br class=""></div><div class="">-Thorsten</div><div class=""><br class=""></div><div class=""><br class=""></div><div class=""><br class=""><div class=""><blockquote type="cite" class=""><div class="">Am 26.05.2016 um 20:11 schrieb Adrian Zubarev via swift-evolution &lt;<a href="mailto:swift-evolution@swift.org" class="">swift-evolution@swift.org</a>&gt;:</div><br class="Apple-interchange-newline"><div class=""><div class="bloop_markdown" style="font-family: Helvetica, Arial; font-size: 13px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px; background-color: rgb(254, 254, 254);"><p style="margin: 15px 0px; -webkit-margin-before: 0px;" class="">Something like<span class="Apple-converted-space">&nbsp;</span><code style="font-family: Menlo, Consolas, 'Liberation Mono', Courier, monospace; font-size: 10pt; border-top-left-radius: 3px; border-top-right-radius: 3px; border-bottom-right-radius: 3px; border-bottom-left-radius: 3px; background-color: rgb(248, 248, 248); color: inherit; border: 1px solid rgb(234, 234, 234); margin: 0px 2px; padding: 0px 5px; word-break: normal; word-wrap: normal; -webkit-margin-before: 0px;" class="">type&lt;…&gt;</code><span class="Apple-converted-space">&nbsp;</span>was considered at the very start of the whole discussion (<a href="https://lists.swift.org/pipermail/swift-evolution/Week-of-Mon-20160502/016523.html" style="color: rgb(65, 131, 196); background-color: inherit; text-decoration: none;" class="">in this thread</a>), but it does not solve the meaning of an existential type and also might lead to even more confusion.<span class="Apple-converted-space">&nbsp;</span></p><p style="margin: 15px 0px;" class="">From my perspective I wouldn’t use parentheses here because it looks more like an init without any label<span class="Apple-converted-space">&nbsp;</span><code style="font-family: Menlo, Consolas, 'Liberation Mono', Courier, monospace; font-size: 10pt; border-top-left-radius: 3px; border-top-right-radius: 3px; border-bottom-right-radius: 3px; border-bottom-left-radius: 3px; background-color: rgb(248, 248, 248); color: inherit; border: 1px solid rgb(234, 234, 234); margin: 0px 2px; padding: 0px 5px; word-break: normal; word-wrap: normal; -webkit-margin-before: 0px;" class="">Type.init(…)</code><span class="Apple-converted-space">&nbsp;</span>or<span class="Apple-converted-space">&nbsp;</span><code style="font-family: Menlo, Consolas, 'Liberation Mono', Courier, monospace; font-size: 10pt; border-top-left-radius: 3px; border-top-right-radius: 3px; border-bottom-right-radius: 3px; border-bottom-left-radius: 3px; background-color: rgb(248, 248, 248); color: inherit; border: 1px solid rgb(234, 234, 234); margin: 0px 2px; padding: 0px 5px; word-break: normal; word-wrap: normal;" class="">Type(…)</code>. I could live with<span class="Apple-converted-space">&nbsp;</span><code style="font-family: Menlo, Consolas, 'Liberation Mono', Courier, monospace; font-size: 10pt; border-top-left-radius: 3px; border-top-right-radius: 3px; border-bottom-right-radius: 3px; border-bottom-left-radius: 3px; background-color: rgb(248, 248, 248); color: inherit; border: 1px solid rgb(234, 234, 234); margin: 0px 2px; padding: 0px 5px; word-break: normal; word-wrap: normal;" class="">Any[…]</code><span class="Apple-converted-space">&nbsp;</span>but this doesn’t look shiny and Swifty to me. Thats only my personal view. ;)</p><div style="margin: 15px 0px;" class=""><br class="webkit-block-placeholder"></div></div><div class="bloop_original_html" style="font-family: Helvetica, Arial; font-size: 13px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px; background-color: rgb(254, 254, 254);"><div id="bloop_customfont" style="font-family: Helvetica, Arial; font-size: 13px; margin: 0px;" class=""><br class=""></div><br class=""><div id="bloop_sign_1464285716927451136" class="bloop_sign"><div style="font-family: helvetica, arial; font-size: 13px;" class="">--&nbsp;<br class="">Adrian Zubarev<br class="">Sent with Airmail</div></div><br class=""><p class="airmail_on" style="margin: 15px 0px;">Am 26. Mai 2016 bei 19:48:04, Vladimir.S via swift-evolution (<a href="mailto:swift-evolution@swift.org" style="color: rgb(65, 131, 196); background-color: inherit; text-decoration: none;" class="">swift-evolution@swift.org</a>) schrieb:</p><blockquote type="cite" class="clean_bq" style="margin: 15px 0px;"><span style="margin-top: 0px; margin-bottom: 0px;" class=""><div class=""><div class=""></div><div class="">Don't think {} is better here, as they also have "established meaning in<span class="Apple-converted-space">&nbsp;</span><br class="">Swift today".<br class=""><br class="">How about just Type(P1 &amp; P2 | P3) - as IMO we can think of such<span class="Apple-converted-space">&nbsp;</span><br class="">construction as "creation" of new type and `P1 &amp; P2 | P3` could be treated<span class="Apple-converted-space">&nbsp;</span><br class="">as parameters to initializer.<br class=""><br class="">func f(t: Type(P1 &amp; P2 | P3)) {..}<br class=""><br class=""><br class="">On 26.05.2016 20:32, L. Mihalkovic via swift-evolution wrote:<br class="">&gt; How about something like Type{P1 &amp; P2 | P3} the point being that "&lt;...&gt;" has an established meaning in Swift today which is not what is expressed in the "&lt;P1,P2,P3&gt;" contained inside Any&lt;P1, P2,P3&gt;.<br class="">&gt;<br class="">&gt;&gt; On May 26, 2016, at 7:11 PM, Dave Abrahams via swift-evolution &lt;<a href="mailto:swift-evolution@swift.org" style="color: rgb(65, 131, 196); background-color: inherit; text-decoration: none;" class="">swift-evolution@swift.org</a>&gt; wrote:<br class="">&gt;&gt;<br class="">&gt;&gt;<br class="">&gt;&gt;&gt; on Thu May 26 2016, Adrian Zubarev &lt;<a href="mailto:swift-evolution@swift.org" style="color: rgb(65, 131, 196); background-color: inherit; text-decoration: none;" class="">swift-evolution@swift.org</a>&gt; wrote:<br class="">&gt;&gt;&gt;<br class="">&gt;&gt;&gt; There is great feedback going on here. I'd like to consider a few things here:<br class="">&gt;&gt;&gt;<br class="">&gt;&gt;&gt; * What if we name the whole thing `Existential&lt;&gt;` to sort out all<br class="">&gt;&gt;&gt; confusion?<br class="">&gt;&gt;<br class="">&gt;&gt; Some of us believe that “existential” is way too theoretical a word to<br class="">&gt;&gt; force into the official lexicon of Swift. I think “Any&lt;...&gt;” is much<br class="">&gt;&gt; more conceptually accessible.<br class="">&gt;&gt;<br class="">&gt;&gt;&gt;<br class="">&gt;&gt;&gt; This would allow `typealias Any = Existential&lt;&gt;`. * Should<br class="">&gt;&gt;&gt; `protocol A: Any&lt;class&gt;` replace `protocol A: class`? Or at least<br class="">&gt;&gt;&gt; deprecate it. * Do we need `typealias AnyClass = Any&lt;class&gt;` or do we<br class="">&gt;&gt;&gt; want to use any class requirement existential directly? If second, we<br class="">&gt;&gt;&gt; will need to allow direct existential usage on protocols (right now we<br class="">&gt;&gt;&gt; only can use typealiases as a worksround).<br class="">&gt;&gt;<br class="">&gt;&gt; --<br class="">&gt;&gt; Dave<br class="">&gt;&gt;<br class="">&gt;&gt; _______________________________________________<br class="">&gt;&gt; swift-evolution mailing list<br class="">&gt;&gt;<span class="Apple-converted-space">&nbsp;</span><a href="mailto:swift-evolution@swift.org" style="color: rgb(65, 131, 196); background-color: inherit; text-decoration: none;" class="">swift-evolution@swift.org</a><br class="">&gt;&gt;<span class="Apple-converted-space">&nbsp;</span><a href="https://lists.swift.org/mailman/listinfo/swift-evolution" style="color: rgb(65, 131, 196); background-color: inherit; text-decoration: none;" class="">https://lists.swift.org/mailman/listinfo/swift-evolution</a><br class="">&gt; _______________________________________________<br class="">&gt; swift-evolution mailing list<br class="">&gt;<span class="Apple-converted-space">&nbsp;</span><a href="mailto:swift-evolution@swift.org" style="color: rgb(65, 131, 196); background-color: inherit; text-decoration: none;" class="">swift-evolution@swift.org</a><br class="">&gt;<span class="Apple-converted-space">&nbsp;</span><a href="https://lists.swift.org/mailman/listinfo/swift-evolution" style="color: rgb(65, 131, 196); background-color: inherit; text-decoration: none;" class="">https://lists.swift.org/mailman/listinfo/swift-evolution</a><br class="">&gt;<br class="">_______________________________________________<br class="">swift-evolution mailing list<br class=""><a href="mailto:swift-evolution@swift.org" style="color: rgb(65, 131, 196); background-color: inherit; text-decoration: none;" class="">swift-evolution@swift.org</a><br class=""><a href="https://lists.swift.org/mailman/listinfo/swift-evolution" style="color: rgb(65, 131, 196); background-color: inherit; text-decoration: none;" class="">https://lists.swift.org/mailman/listinfo/swift-evolution</a><br class=""></div></div></span></blockquote></div><div class="bloop_markdown" style="font-family: Helvetica, Arial; font-size: 13px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px; background-color: rgb(254, 254, 254);"><div style="margin: 15px 0px; -webkit-margin-before: 0px;" class=""><br class="webkit-block-placeholder"></div></div><span style="font-family: Helvetica, Arial; font-size: 13px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px; background-color: rgb(254, 254, 254); float: none; display: inline !important;" class="">_______________________________________________</span><br style="font-family: Helvetica, Arial; font-size: 13px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px; background-color: rgb(254, 254, 254);" class=""><span style="font-family: Helvetica, Arial; font-size: 13px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px; background-color: rgb(254, 254, 254); float: none; display: inline !important;" class="">swift-evolution mailing list</span><br style="font-family: Helvetica, Arial; font-size: 13px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px; background-color: rgb(254, 254, 254);" class=""><a href="mailto:swift-evolution@swift.org" style="color: rgb(65, 131, 196); background-color: rgb(254, 254, 254); text-decoration: none; font-family: Helvetica, Arial; font-size: 13px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px;" class="">swift-evolution@swift.org</a><br style="font-family: Helvetica, Arial; font-size: 13px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px; background-color: rgb(254, 254, 254);" class=""><a href="https://lists.swift.org/mailman/listinfo/swift-evolution" style="color: rgb(65, 131, 196); background-color: rgb(254, 254, 254); text-decoration: none; font-family: Helvetica, Arial; font-size: 13px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px;" class="">https://lists.swift.org/mailman/listinfo/swift-evolution</a><br style="font-family: Helvetica, Arial; font-size: 13px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px; background-color: rgb(254, 254, 254);" class=""></div></blockquote></div><br class=""></div></div></blockquote><blockquote type="cite" class=""><div class=""><span class="">_______________________________________________</span><br class=""><span class="">swift-evolution mailing list</span><br class=""><span class=""><a href="mailto:swift-evolution@swift.org" class="">swift-evolution@swift.org</a></span><br class=""><span class=""><a href="https://lists.swift.org/mailman/listinfo/swift-evolution" class="">https://lists.swift.org/mailman/listinfo/swift-evolution</a></span><br class=""></div></blockquote></div></div></blockquote></div><br class=""></div></div></div>_______________________________________________<br class="">swift-evolution mailing list<br class=""><a href="mailto:swift-evolution@swift.org" class="">swift-evolution@swift.org</a><br class="">https://lists.swift.org/mailman/listinfo/swift-evolution<br class=""></div></blockquote></div><br class=""></body></html>