<div dir="ltr">Just thinking out loud here:<div><br></div><div>&quot;x&#39;s intersection with y&quot; makes sense. So &quot;x.intersection(with: y)&quot; makes sense.  That&#39;s already in Dave&#39;s diff.</div><div><br></div><div>Unfortunately the same doesn&#39;t work well for &quot;x&#39;s union with y&quot; — should &quot;x.union(with: y)&quot; be a mutating or nonmutating operation? Hard to tell.</div><div><br></div><div>How about we just move to ∪ and ∪= operators and call it a day? :-)</div><div><div><div class="gmail_extra">
<br><div class="gmail_quote">On Thu, Feb 11, 2016 at 11:36 AM, Erica Sadun <span dir="ltr">&lt;<a href="mailto:erica@ericasadun.com" target="_blank">erica@ericasadun.com</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex"><div style="word-wrap:break-word"><div>Assuming one would want to avoid the -ed suffix (and also -ing), one might consider:</div><div><br></div><div>* intersectionOf(), orOf(), unionOf() (or &quot;With&quot; over &quot;Of&quot;)</div><div>* setIntersection(), setOr(), setUnion(),</div><div>* intersectionResult(), orResult(), unionResult(),</div><div>etc</div><span class=""><font color="#888888"><div><br></div><div>-- E</div></font></span><div><div class="h5"><div><br></div><br><div><blockquote type="cite"><div>On Feb 11, 2016, at 12:28 PM, Jacob Bandes-Storch &lt;<a href="mailto:jtbandes@gmail.com" target="_blank">jtbandes@gmail.com</a>&gt; wrote:</div><br><div><div dir="ltr">&quot;intersected&quot; sounds okay to me. &quot;unioned&quot; is borderline, and &quot;ored&quot; is not something I&#39;d want in the standard library. Neither is &quot;oring&quot;.<div class="gmail_extra">
<br><div class="gmail_quote">On Thu, Feb 11, 2016 at 11:25 AM, Erica Sadun <span dir="ltr">&lt;<a href="mailto:erica@ericasadun.com" target="_blank">erica@ericasadun.com</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex"><div style="word-wrap:break-word"><div>I see the -ed versions as short for -edSet, with the Set being implied. Under this reasoning, unioned == unionedSet, intersected == intersectedSet, thus acting as nouns not verbs, and used for non-mutating application.</div><div><br></div><div>inPlace is only for mutating application. I mildly prefer the shorter union to unionInPlace, although I could argue both sides. (The latter is clearer but longer, the former is the short verb action that the whole guideline thing is supposed to endorse.)</div><span><font color="#888888"><div><br></div><div>-- E</div></font></span><div><div><div><br></div><div><blockquote type="cite"><div>On Feb 11, 2016, at 12:19 PM, Jacob Bandes-Storch &lt;<a href="mailto:jtbandes@gmail.com" target="_blank">jtbandes@gmail.com</a>&gt; wrote:</div><br><div><div dir="ltr"><div class="gmail_extra"><div class="gmail_quote">On Thu, Feb 11, 2016 at 11:09 AM, Erica Sadun via swift-evolution <span dir="ltr">&lt;<a href="mailto:swift-evolution@swift.org" target="_blank">swift-evolution@swift.org</a>&gt;</span> wrote:<blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex"><div style="word-wrap:break-word"><div><b>Non-Mutating, returning new value</b>: unioned(with), intersected(with), exclusiveOred(with)</div><div><br></div><div>Reasoning:</div><div><br></div><div>* <b>I think the -ing endings sound unnatural, stilted, and unmathematical. </b>They make me wince.</div></div></blockquote><div><br></div><div>So do the -ed versions, IMO. That&#39;s why -InPlace is such a convenient suffix.</div><div><br></div><div>Jacob</div></div></div></div>
</div></blockquote></div><br></div></div></div></blockquote></div><br></div></div>
</div></blockquote></div><br></div></div></div></blockquote></div><br></div></div></div></div>