f-script
Greg A. Woods
woods at weird.com
Tue Nov 20 06:07:52 UTC 2001
[ On Monday, November 19, 2001 at 17:31:46 (-0800), Tim Rowledge wrote: ]
> Subject: RE: f-script
>
> woods at weird.com (Greg A. Woods) is widely believed to have written:
> >
> > In Smalltalk syntax one of the problems with symbols like you suggest,
> > or any new keywords that look like words, is that they're much more
> > easily confused with message selectors or variable names, etc.
>
> But, but, they _are_ message selectors!
Ah, no, I don't believe they are, at least not in F-script proper. They
are more like meta-modifiers to message selectors.
Whether it makes sense to implement them as normal message selectors in
another Smalltalk is perhaps the question I'm asking.
> > Perhaps a better choice than '@' would be an entirely new glyph, though
> Squeak uses '@' - all over the place. As in a at b being a Point with x=a
> and y=b.
Ah, yes, the Point class -- I forgot about that one! The depth of my
day-to-day Squeak experience is showing through! ;-)
That "@" is of course just a binary message to a number, and of course
there are other, albiet less intuitive and less compact, ways to write a
statement to return a new Point object. :-)
Perhaps the symbol used as the "shape" operator in APL (lowercase Rho)
would be a potential alternative new glyph for this meta operator?
> Mixing operators with message sending is a recipe for confusion. :-(
That's the problem though -- as identified in Mougin's paper, there's no
way to get the full power of array programming into a Smalltalk-like
syntax without extending the message sending paradigm to allow for the
sending of a complex group of messages using a simple, compact, and
transparent syntax. To quote from the paper:
[5.3.2] When the "@" symbol is placed after the message
recipient and/or just before the arguments, it means that a loop
on [the] designated arrays must be run in order to generate
message sends.
We're not talking about simple message selectors here, but a kind of
meta-modifier of message selectors!
It would appear that F-script is not just an interesting extension
proposal to Smalltalk, but also a practical demonstration of a working
language that's capable of doing things that are much harder to do in
plain Smalltalk.
--
Greg A. Woods
+1 416 218-0098 VE3TCP <gwoods at acm.org> <woods at robohack.ca>
Planix, Inc. <woods at planix.com>; Secrets of the Weird <woods at weird.com>
More information about the Squeak-dev
mailing list
|