binary selectors ambiguity and space
ncellier at ifrance.com
Sat May 13 17:54:54 UTC 2006
Le Samedi 13 Mai 2006 19:43, nicolas cellier a écrit :
> Dan said space should not be significant...
> In fact, if you look Squeak literal arrays, or VW implementation, you can
> see that in fact it is: #(1-2) and #(1- 2)
To be correct, space put around binary selectors should not be significant.
That is (1 - -2) should lead same result as (1--2).
This is not exactly the same as space placed between minus sign and following
digit like in my example. Space are significant as a separator of course, and
(- 2) should maybe not be interpreted as a literal constant (nor a valid
expression). In VW, this syntax is rejected, you can check the bible again.
More information about the Squeak-dev