[squeak-dev] Re: Hello list

Bert Freudenberg bert at freudenbergs.de
Wed Apr 20 13:05:36 UTC 2011


On 20.04.2011, at 06:56, Rodney Polkinghorne wrote:
>> Be sure to look at class Complex in the image.
> 
> I found that, tried it, and got sick of saying "0 asComplex" in about
> two minutes.  Someone must have been there before; Number currently
> accepts an #argument message, and answers 0 or pi according to sign.
> I think everything that knows its modulus and argument should know its
> real and imaginary parts.

That would be trivial to add to Number. What else do you think is missing?

> I like the syntactic pun by which Number accepts a message #i.

So why don't you write 0i instead of "0 asComplex"?

- Bert -





More information about the Squeak-dev mailing list