help-smalltalk
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Help-smalltalk] [PATCH] Fix spurious failure in floatmath.st


From: Stephen Compall
Subject: Re: [Help-smalltalk] [PATCH] Fix spurious failure in floatmath.st
Date: Fri, 25 May 2007 11:43:31 -0500

On Fri, 2007-05-25 at 11:03 +0200, Paolo Bonzini wrote:
> st> LookupTable new capacity
> 6
> st> LookupTable new copy capacity
> 12
> st> LookupTable new copy copy capacity
> 24
> st> LookupTable new copy copy copy capacity
> 48

Ironically, I had fixed one case of this by adding #copyEmpty to
HashedCollection, then broke it again by changing #new:'s semantics.
Guess I should run the Presource test suite more often :)

> --- orig/kernel/LookupTable.st
> +++ mod/kernel/LookupTable.st
> @@ -116,7 +116,7 @@ deepCopy
>      "Returns a deep copy of the receiver (the instance variables are
>       copies of the receiver's instance variables)"
>      | key newDict |
> -    newDict := self copyEmpty: self primSize.
> +    newDict := self copyEmpty: self capacity.
>      1 to: self primSize do: [ :index |

This seems to require that {capacities} -> {primSizes} is a pure
function with class-level granularity.  Is that permitted by the
protocol?

> -AT_DIFF_TEST([floatmath.st], [AT_XFAIL_IF(:)])
> +AT_DIFF_TEST([floatmath.st])

Great, I'll retest this with patch-356 on Darwin/x86.

-- 
;;; Stephen Compall ** http://scompall.nocandysw.com/blog **
Failure to imagine vast possibilities usually stems from a lack of
imagination, not a lack of possibility.

Attachment: signature.asc
Description: This is a digitally signed message part


reply via email to

[Prev in Thread] Current Thread [Next in Thread]