Waldemar Kornewald wrote on Fri, 23 Nov 2007 12:56:48 +0100
> On Nov 23, 2007 1:36 AM, Wm Annis wrote:
> > (Oops.  Sent only to WK first.)
> 
> I hope the mailing list settings get fixed at some point.

Well, this is just another example of how things aren't as simple as you
think they are. The current settings cause a set of problems but
changing them won't "fix things" - it would just cause a different set
of problems (people sending messages that they wanted to keep private to
the whole list, for example).
 
> > *Everything* we do to communicate with computers is pretty unnatural.
> > I don't see how learning different precedence rules to program is any
> > different from learning that "if (a == 3 or 4 or 5) ..." doesn't mean the
> > same thing to a computer that it means in English.
> 
> Is this an excuse to make computer suck? What are we talking about here?
> 
> Let's stop thinking in terms of implementation complexity (math
> precedence won't add much, anyway) and start thinking in terms of how
> to make computers easier, more natural, and less error-prone for
> end-users (in this case, programmers using COLA).

Having no operator precendence causes some problems, having them causes
other problems. Some people will always have problems with one option,
others with the opposite option and still others will have problems with
all options at different times. This is like the email list options or
having arrays indexed starting with 0 vs starting with 1.

Note that APL was originally created as a math notation and it abandoned
operator precedence as too error prone for humans. Lisp was mentioned
and Forth is another example, but APL uses infix notation and so is more
relevant for this discussion.

It is interesting that Apple Logo had reasonably conventional
precendence but TI Logo didn't. When I created SuperLogo in 1983 and
then NeoLogo in 1994 this issue took up a significant part of my
language design and implementation time. Like you said, the
implementation complexity is not a problem at all. Anything we can
imagine can be done rather easily. The real problem is having a scheme
that makes sense to the users.

One possible answer is "to each his own". Letting everyone change
everything is one of the whole points of COLA, after all. But if people
need to work together then choices have to be made, as the mess that was
created in Smalltalk-72 and -74 (where everyone defined their own
syntaxes) proved so well.

The C precedence rules are very popular right now, but they are often
confusing. And these rules only go so far in matching conventional math
notation (of which there are several incompatible variations, hence the
APL effort). Personally, I think that if you are going to follow that
path then what the Fortress guys (no pun intended) are doing is a good
option.

-- Jecel

_______________________________________________
fonc mailing list
[email protected]
http://vpri.org/mailman/listinfo/fonc

Reply via email to