Re: Definable operators

apardon@rc4.vub.ac.be (Antoon Pardon)
20 Apr 1997 12:07:29 -0400

          From comp.compilers

Related articles
[17 earlier articles]
Re: Definable operators nmm1@cus.cam.ac.uk (1997-04-16)
Re: Definable operators raw@math.wisc.edu (Matthew J. Raw) (1997-04-16)
Re: Definable operators dlester@cs.man.ac.uk (1997-04-16)
Re: Definable operators fanf@lspace.org (Tony Finch) (1997-04-18)
Re: Definable operators monnier+/news/comp/compilers@tequila.cs.yale.edu (Stefan Monnier) (1997-04-18)
Re: Definable operators burley@tweedledumb.cygnus.com (Craig Burley) (1997-04-18)
Re: Definable operators apardon@rc4.vub.ac.be (1997-04-20)
Re: Definable operators genew@vip.net (1997-04-20)
Re: Definable operators kumo@intercenter.net (David Rush) (1997-04-20)
Re: Definable operators burley@tweedledumb.cygnus.com (Craig Burley) (1997-04-22)
Re: Definable operators burley@tweedledumb.cygnus.com (Craig Burley) (1997-04-30)
Re: Definable operators hrubin@stat.purdue.edu (1997-04-30)
Re: Definable operators apardon@rc4.vub.ac.be (1997-05-04)
[15 later articles]
| List of all articles for this month |
From: apardon@rc4.vub.ac.be (Antoon Pardon)
Newsgroups: comp.compilers
Date: 20 Apr 1997 12:07:29 -0400
Organization: Brussels Free Universities (VUB/ULB), Belgium
References: 97-03-037 97-03-076 97-03-112 97-03-115 97-03-141 97-03-162 97-03-184 97-04-027 97-04-095 97-04-113
Keywords: syntax, design

Craig Burley (burley@tweedledumb.cygnus.com) wrote:


: Programmers have been "taught" that doing more things with less input
: is so highly valuable that they forget that the purpose of _language_
: design is to make works written in the language more readily
: understood by their _human_ audience. And doing that properly usually
: requires _restricting_ the expressiveness of the language --
: e.g. explicitly saying that + cannot be made to mean anything other
: than addition, even if the tools that process the language cannot be
: made to enforce such a restriction.


I don't have a problem with what you write here. I just don't
understand why this seems to remain limited to operators. Can't we
just as reasonably assert that a function "insert" cannot be made to
mean anything other than something we understand as insertion even if
the tools that process the language cannot be made to enforce such a
restriction. I just don't understand why some people seem to think
the problem is different because we have infix symbolic notation
instead of prefix alfabetic notation. The problem is the language
can't be defined in such a way that it is made impossible to choose
bad names. Either by choosing '+' for something that has no
connection with addition or by choosing 'insert' for something that
has no connection with insertable items. The difference between the
two seems an unimportant detail.


So go ahead and warn everybody about the advantage of good choice of
names. Explain why you think "+" is a bad name for string
concatenation.


But faulting the language because it allows "+" to be used
inappropiately while we don't seem to have problems with languages
that allow "insert" to be used inappropiately doesn't make sense to
me.


--
Antoon Pardon Brussels Free University Computing Centre
--


Post a followup to this message

Return to the comp.compilers page.
Search the comp.compilers archives again.