Last night I wanted to round a number to an arbitrary precision; (finally got sick of calculating tips in workspaces, heh) is that what this is for (seems like it?)<br><br><div class="gmail_quote">On Sun, May 2, 2010 at 12:39 PM,  <span dir="ltr">&lt;<a href="mailto:commits@source.squeak.org">commits@source.squeak.org</a>&gt;</span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">A new version of Kernel was added to project The Inbox:<br>
<a href="http://source.squeak.org/inbox/Kernel-wiz.444.mcz" target="_blank">http://source.squeak.org/inbox/Kernel-wiz.444.mcz</a><br>
<br>
==================== Summary ====================<br>
<br>
Name: Kernel-wiz.444<br>
Author: wiz<br>
Time: 2 May 2010, 3:39:34.852 pm<br>
UUID: 3a8f4eb1-7d22-4398-a30b-0c674e73a0f7<br>
Ancestors: Kernel-ar.443<br>
<br>
This adds Number&gt;&gt;roundDownTo:<br>
<br>
Currently it is missing. Essentialy it is an umimplemented call. Called by:<br>
&#39;Point roundDownTo: {*Morphic-Truncation and Roundoff}&#39; &#39;Rectangle compressTo: {*Morphic-Truncation and Roundoff}&#39; &#39;Rectangle expandTo: {*Morphic-Truncation and Roundoff}&#39;<br>
<br>
It doesn&#39;t show up as unimplemented because the selector is used by Point. However, if it is not present the other three methods will raise a stink.<br>
<br>
<br>
<br>
=============== Diff against Kernel-ar.443 ===============<br>
<br>
Item was added:<br>
+ ----- Method: Number&gt;&gt;roundDownTo: (in category &#39;truncation and round off&#39;) -----<br>
+ roundDownTo: aNumber<br>
+       &quot;Answer the next multiple of aNumber toward negative infinity that is nearest the<br>
+       receiver.&quot;<br>
+<br>
+       ^(self/aNumber) floor * aNumber!<br>
<br>
<br>
</blockquote></div><br><br clear="all"><br>-- <br>Casey Ransberger<br>