<div dir="ltr"><br><div class="gmail_extra"><br><div class="gmail_quote">On Wed, Apr 8, 2015 at 1:09 AM, Tobias Pape <span dir="ltr">&lt;<a href="mailto:Das.Linux@gmx.de" target="_blank">Das.Linux@gmx.de</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi Eliot<br>
<span class=""><br>
On 08.04.2015, at 09:56, Eliot Miranda &lt;<a href="mailto:eliot.miranda@gmail.com">eliot.miranda@gmail.com</a>&gt; wrote:<br>
<br>
&gt; Hi Tobias,<br>
&gt;<br>
&gt;     hasClassNamed: and symbols are to be preferred to avoid the cost of interning.<br>
<br>
</span>I don&#39;t quite understand that. When I use a symbol, it already has been interned,<br>
either during method-compilation or because I created it. How is interning avoided here?<br>
  I thought this was the very reason to not pass a Symbol to hasClassNamed?<br>
What about its sibling classNamed: (or classOrTraitNamed:)?<br>
<span class=""><br>
&gt; The class name keys are, as they should be, symbols, and we don&#39;t want to pay the cost of interning to do that lookup.  And I agree with Levente that symbols are searched for when SystemNavigation is used to find such soft class references.<br>
<br>
</span>Right, I did not argue against that :)<br></blockquote><div><br></div><div>I misunderstood.  So this discussion is just about the argument name?  In any case I&#39;m with Bert for using symbols to refer to class names whereever possible.</div><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<span class=""><br>
&gt;  Your string position is understandable but needlessly expensive.  The use of symbols (and the assumption that they&#39;re strings) is simple and efficient.<br>
<br>
</span>Don&#39;t get me wrong, I think that this assumption is worthwhile in (at least)<br>
Core Squeak, yes.<br>
<br>
Best<br>
<span class="HOEnZb"><font color="#888888">        -Tobias :)<br>
</font></span><div class="HOEnZb"><div class="h5"><br>
&gt;<br>
&gt; Eliot (phone)<br>
&gt;<br>
&gt; On Apr 7, 2015, at 8:21 AM, Tobias Pape &lt;<a href="mailto:Das.Linux@gmx.de">Das.Linux@gmx.de</a>&gt; wrote:<br>
&gt;<br>
&gt;&gt;<br>
&gt;&gt; On 07.04.2015, at 17:16, Levente Uzonyi &lt;<a href="mailto:leves@elte.hu">leves@elte.hu</a>&gt; wrote:<br>
&gt;&gt;<br>
&gt;&gt;&gt; What&#39;s wrong with #hasClassNamed:?<br>
&gt;&gt;<br>
&gt;&gt; From my POV, it takes a String, and we wanted a symbol here ;)<br>
&gt;&gt; Also, I wanted t be conisten with #setUP<br>
&gt;&gt;<br>
&gt;&gt;&gt;<br>
&gt;&gt;&gt; Levente<br>
&gt;&gt;&gt;<br>
&gt;&gt;&gt; On Tue, 7 Apr 2015, <a href="mailto:commits@source.squeak.org">commits@source.squeak.org</a> wrote:<br>
&gt;&gt;&gt;<br>
&gt;&gt;&gt;&gt; Tobias Pape uploaded a new version of EToys to project The Trunk:<br>
&gt;&gt;&gt;&gt; <a href="http://source.squeak.org/trunk/EToys-topa.123.mcz" target="_blank">http://source.squeak.org/trunk/EToys-topa.123.mcz</a><br>
&gt;&gt;&gt;&gt;<br>
&gt;&gt;&gt;&gt; ==================== Summary ====================<br>
&gt;&gt;&gt;&gt;<br>
&gt;&gt;&gt;&gt; Name: EToys-topa.123<br>
&gt;&gt;&gt;&gt; Author: topa<br>
&gt;&gt;&gt;&gt; Time: 7 April 2015, 2:37:32.593 pm<br>
&gt;&gt;&gt;&gt; UUID: 71b565ae-57ad-4d33-91d2-d6bfeec75490<br>
&gt;&gt;&gt;&gt; Ancestors: EToys-topa.122<br>
&gt;&gt;&gt;&gt;<br>
&gt;&gt;&gt;&gt; the ifPresent: part needs a block argument<br>
&gt;&gt;&gt;&gt;<br>
&gt;&gt;&gt;&gt; =============== Diff against EToys-topa.122 ===============<br>
&gt;&gt;&gt;&gt;<br>
&gt;&gt;&gt;&gt; Item was changed:<br>
&gt;&gt;&gt;&gt; ----- Method: TileMorphTest&gt;&gt;expectedFailures (in category &#39;testing&#39;) -----<br>
&gt;&gt;&gt;&gt; expectedFailures<br>
&gt;&gt;&gt;&gt;<br>
&gt;&gt;&gt;&gt;   ^ super expectedFailures,<br>
&gt;&gt;&gt;&gt;       (self class environment<br>
&gt;&gt;&gt;&gt;           at: #BaseSoundSystem<br>
&gt;&gt;&gt;&gt; +            ifPresent: [:e| #()]<br>
&gt;&gt;&gt;&gt; -            ifPresent: [#()]<br>
&gt;&gt;&gt;&gt;           ifAbsent: [#(testSoundTile) &quot;Only this test depends on Sound&quot;])!<br>
<br>
<br>
<br>
</div></div></blockquote></div><br><br clear="all"><div><br></div>-- <br><div class="gmail_signature">best,<div>Eliot</div></div>
</div></div>