[squeak-dev] Re: Ideas about sets and dictionaries
Andreas Raab
andreas.raab at gmx.de
Thu Nov 12 01:17:49 UTC 2009
Eliot Miranda wrote:
> Neat. It might be even easier to use floating point to indicate nil :)
> So if
> tally class = SmallInteger
> it doesn't include nil, but if
> tally class = Float
> it does. Once tally has been set to a Double all the loops still work,
> increasing the tally still works, etc.
Ouch! Can we please step back a little and instead of coming up with
ever more clever hacks think a bit about how we'd solve the problem if
we would address it from first principles? Nothing against cool hacks
but that is getting so obscure that I'd rather not have nil in sets at
all than having to live with the hacks that have been proposed.
Seriously, how *would* you address this problem if you weren't trying to
make it fit exactly?
Cheers,
- Andreas
More information about the Squeak-dev
mailing list
|