[plt-scheme] How to make unit functors?
Matthew Flatt wrote:
> At Wed, 28 May 2003 19:21:42 +0200, Jens_Axel_Søgaard wrote:
>> I have just checked that even though 'j and 'J are eq?
>> then have different hash-codes.
>
> That can't be right.
> > (eq? 'j 'J)
> #t
> > (eq-hash-code 'j)
> 511627
> > (eq-hash-code 'J)
> 511627
>
> The number will be different on your machine, but both `eq-hash-code'
> results have to be the same number.
I get these strange results on a WinXP 204:
> (eq-hash-code 'j)
26876924
> (eq-hash-code 'j)
26876924
> (eq-hash-code 'j)
26876924
> (eq-hash-code 'j)
26876924
> (eq-hash-code 'j)
27106264
> (eq-hash-code 'j)
27106264
> (eq-hash-code 'j)
27106264
The hash code suddenly changes?
Unless it's a bug, I'm more confused than ever.
--
Jens Axel Søgaard