[squeak-dev] WideString hash is way slower than ByteString hash.
Igor Stasenko
siguctua at gmail.com
Fri May 14 23:00:43 UTC 2010
On 15 May 2010 01:53, <christophe.jalady at free.fr> wrote:
> Should the hash function be the same between ByteString and WideString ?
> I mean: if a WideString contains the same characters than a ByteString, I guess that they should have both the same hashcode no ?
>
Seems so.
|s |
s := (WideString with: (Character value: 16r55E4)) , 'abcdefghijklmno'.
s at: 1 put: $a.
s class. WideString
s nbHash. 196130722
s nbHash 196130722
'aabcdefghijklmno' hash 196130722
--
Best regards,
Igor Stasenko AKA sig.
More information about the Squeak-dev
mailing list
|