Re: Definable operators (Herman Rubin)
11 Apr 1997 00:05:22 -0400

          From comp.compilers

Related articles
[9 earlier articles]
Re: Definable operators (1997-03-31)
Re: Definable operators (1997-04-02)
Re: Definable operators (Dave Lloyd) (1997-04-02)
Re: Definable operators (Craig Burley) (1997-04-03)
Re: Definable operators (Francois-Rene Rideau) (1997-04-03)
Re: Definable operators (Jerry Leichter) (1997-04-06)
Re: Definable operators (1997-04-11)
Re: Definable operators (1997-04-16)
Re: Definable operators (Matthew J. Raw) (1997-04-16)
Re: Definable operators (1997-04-16)
Re: Definable operators (Tony Finch) (1997-04-18)
Re: Definable operators monnier+/news/comp/ (Stefan Monnier) (1997-04-18)
Re: Definable operators (Craig Burley) (1997-04-18)
[22 later articles]
| List of all articles for this month |

From: (Herman Rubin)
Newsgroups: comp.compilers,comp.lang.misc
Date: 11 Apr 1997 00:05:22 -0400
Organization: Purdue University Statistics Department
References: 97-03-037 97-03-162 97-04-018 97-04-034
Keywords: syntax, design

Jerry Leichter <> wrote:


> 2. For operators that either have no widely-used meaning at
> all, or have a limited meaning, just about any
> *self-consistent* usage is OK. The use of << and >>
> for I/O in C++ are a good example: << and >> are
> rare in mathematics ("much less than/greater than"),
> and that meaning is unlikely to be significant in
> programming usage. Shifting isn't all that common
> an operation in C or C++, and has no properties (like
> commutativity or associativity) that anyone thinks
> about. So giving these operators entirely new meanings
> makes perfect sense.

The claim that shifting is "not that common" is questionable. I have
used it much more for other purposes than I have done other than
simple formatted I/O, for which it is not needed.

This is one of the problems of language designers and compiler
writers, and even for hardware designers. It is often quite easy to
put something in at design time, and quite difficult to find a
work-around later. It is quite easy to destroy common notation for
computer purposes, and hard to get it back.
Herman Rubin, Dept. of Statistics, Purdue Univ., West Lafayette IN47907-1399 Phone: (765)494-6054 FAX: (765)494-0558

Post a followup to this message

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