[Pharo-project] Set with nil
tibabenfortlapalanca at gmail.com
Fri May 20 11:36:04 CEST 2011
On a dropdown menu where you can choose between 'apple' -> #apple, 'orange'
-> #orange or 'nothing' -> nil, for example :)
2011/5/20 Henrik Sperre Johansen <henrik.s.johansen at veloxit.no>
> On 20.05.2011 11:14, Mariano Martinez Peck wrote:
>> please please please I want that!
>> I want to be able to do:
>> add: 'mariano';
>> add: nil;
>> add: 'guille';
>> add: nil.
>> aSet size -> 3
>> aSet contains: nil -> true
>> aSet remove: nil.
>> aSet contains: nil -> false
> It's not like I'm principaly against it, but... why?
> Other than treating all objects equally, I mean?
> I honestly can't come up with a single case where I'd want to put nil in a
> Set on purpose.
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the Pharo-project