[E-Lang] dot vs. space

Mark S. Miller markm@caplet.com
Tue, 03 Apr 2001 15:52:03 -0700


At 03:25 PM Tuesday 4/3/01, Eric Messick wrote:
>A question for MarkM on the dot vs. space issue:
>
>Does the grammar permit the usage of both?  

Currently it doesn't, as the use of '.' for JavaBeans-convention-oriented 
property access is still in the pocket, and needs to be through one major 
release (the upcoming 0.8.10), to facilitate current E users converting to 
the new syntax incrementally.

If no one speaks up for this in-pocket usage, it'll go away immediately 
after 0.8.10, in which case the grammar could easily permit use of both.

Because of this timing issue, and because 0.8.9t isn't out yet because of a 
whole pile of syntactic improvement that are great, but that I hadn't 
expected, I personally am going to try to avoid investing much energy in 
discussing dot until after 0.8.10 is released.

>If so, the standard could
>be to use dot in programs and space for command line invocations.  If
>you slipped up, either would work in either context.
>
>Now, there's an obvious downside:  confusion between the two methods.
>It may make up for this by being familiar to the C tradition people,
>while still looking like a shell when used that way.

I agree with your summary of the pros and cons.  I think the confusion of 
allowing these to be mixed in a single program is rather horrible though.


>Another possibility is to only allow the space at an interactive
>prompt, or at the top level.

Yes, that's possible.  I'd also find it ugly.  Yet another possibility would 
be to allow the programmer to type either, but always convert to a dot, and 
always show a dot.  Zooko's imminent command line completer will probably do 
that as soon as the programmer types a character that makes it unambiguous 
that a dot is needed. ;)


>Unfortunately, I'm in no position to judge how confused newbies would
>be by any of this.

No less of a position than most of the rest of us ;)


        Cheers,
        --MarkM