[Newbies] What does the -> symbol mean?
Andy Burnett
andy.burnett at knowinnovation.com
Wed Jul 30 13:34:18 UTC 2008
>
> <<It's actually a binary (one-argument, infix) method, like +, =, or ==;
> it's the - and > characters put together rather than being a
> specialized glyph like the left arrow was. It creates an Association,
> which is a key-value pair used in things like Dictionaries.
>
> If I remember correctly, any characters which can be used for binary
> methods can be strung together to make other binary methods -
> sometimes you'll see these turn up in specialized contexts. For
> example, there's also ==>, on Booleans, for implication ("a implies b").
>
> Ben Schroeder>>
Thanks Ben, that makes a lot of sense. It's similar to how 1 @ 2 will return
a point. And, of course, after reading your answer I realised that what I
should have done is used the method finder to look up ->. I just haven't
quite got it into my head that there are only objects and messages, and
therefore if something isn't an object, it has to be a message! :-)
Cheers
AB
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.squeakfoundation.org/pipermail/beginners/attachments/20080730/d108dcc7/attachment.htm
More information about the Beginners
mailing list