<div id="__MailbirdStyleContent" style="font-size: 10pt;font-family: Arial;color: #000000;text-align: left" dir="ltr">
Hmm... looking at performance ... why not just add #asSequenceableCollection, which would only impact Set arguments?<div><br></div><div>As a programmer, I do not want to choose between #merge: and #quickMerge:. Or similar. :-)</div><div><br></div><div>Best,</div><div>Marcel</div><div class="mb_sig"></div>
<blockquote class="history_container" type="cite" style="border-left-style: solid;border-width: 1px;margin-top: 20px;margin-left: 0px;padding-left: 10px;min-width: 500px">
<p style="color: #AAAAAA; margin-top: 10px;">Am 13.02.2021 17:05:07 schrieb commits@source.squeak.org <commits@source.squeak.org>:</p><div style="font-family:Arial,Helvetica,sans-serif">Nicolas Cellier uploaded a new version of Graphics to project The Inbox:<br>http://source.squeak.org/inbox/Graphics-nice.446.mcz<br><br>==================== Summary ====================<br><br>Name: Graphics-nice.446<br>Author: nice<br>Time: 13 February 2021, 5:04:52.453325 pm<br>UUID: d13c1db2-370f-4fa6-b7ae-e6766bf0c8fb<br>Ancestors: Graphics-dtl.445<br><br>Let Rectangle merging:/encompassing: an unordered collection.<br><br>=============== Diff against Graphics-dtl.445 ===============<br><br>Item was changed:<br> ----- Method: Rectangle class>>encompassing: (in category 'instance creation') -----<br> encompassing: listOfPoints<br> "A number of callers of encompass: should use this method."<br> | topLeft bottomRight |<br>+ topLeft := bottomRight := listOfPoints anyOne.<br>+ listOfPoints do:<br>- topLeft := bottomRight := listOfPoints first.<br>- listOfPoints allButFirstDo:<br> [:p |topLeft := topLeft min: p.<br>+ bottomRight := bottomRight max: p].<br>- bottomRight := bottomRight max: p].<br> ^self origin: topLeft corner: bottomRight<br> !<br><br>Item was changed:<br> ----- Method: Rectangle class>>merging: (in category 'instance creation') -----<br> merging: listOfRects <br> "A number of callers of merge: should use this method."<br>+ | aRectangle bottomRight topLeft |<br>+ aRectangle := listOfRects anyOne.<br>+ topLeft := aRectangle topLeft.<br>+ bottomRight := aRectangle bottomRight.<br>- | bottomRight topLeft |<br>- topLeft := listOfRects first topLeft.<br>- bottomRight := listOfRects first bottomRight.<br> listOfRects<br>+ do: [:r | topLeft := topLeft min: r topLeft.<br>- allButFirstDo: [:r | topLeft := topLeft min: r topLeft.<br> bottomRight := bottomRight max: r bottomRight].<br> ^self origin: topLeft corner: bottomRight.<br> !<br><br><br></div></blockquote></div>