Newbie question

subbukk subbukk at gmail.com
Mon Jul 23 19:27:21 UTC 2007


On Monday 23 July 2007 11:39 pm, Bert Freudenberg wrote:
> Right - just like a block it evaluates all statements in turn,
> separated by periods. But whereas a block returns the result of the
> last statement, the brace construct collects all results and returns
> them as an array.
Braces differ from blocks in another aspect too. The order of evaluation need 
not be specified for a brace construct.

But this still doesn't answer why period was chosen to be a separator in spite 
of the parsing ambiguity while other non-ambiguous tokens were available?

> Now, at one point the compiler even supported this:
>
> 	{a. b} := {1. 2}
>
> which I found cool but was considered evil, even by those who
> tolerate the braces ...
To be really evil, the order of eval should be unspecified :-). Imagine each 
expr being evaluated by a separate kernel thread on a multiprocessor machine!

Regards .. Subbu



More information about the Squeak-dev mailing list