[1049] in java-interest
Re: java-interest-digest V1 #122
daemon@ATHENA.MIT.EDU (Thomas Breuel)
Thu Aug 17 18:50:30 1995
Date: Thu, 17 Aug 1995 12:26:26 -0700
From: <tmb@almaden.ibm.com> (Thomas Breuel)
To: java-interest@java.sun.com
In-Reply-To: <199508170630.XAA09109@webrunner.neato.org>
Reply-To: <tmb@almaden.ibm.com>
Someone mentioned operators in SML on this list. Several comments on
that:
-- SML does not have operator overloading (but it does allow
built-in operators to be shadowed)
-- SML does allow user-defined operators
From my experience using SML, those are not very good choices. People
will come up with all sorts of wierd user-defined operators on
numerical types that are intended to look similar to the operators
users would like to overload but can't (e.g., "&+" for matrix
addition, etc.). You also get a lot of incomprehensible shorthands
like "<==<" with unguessable precedence.
If you limited operator definitions to overloading of built-in
operators, reasonable programmers will stick with definitions that are
closely analogous to the built-in ones, and that is good.
Letting the user introduce new operator symbols, however, is
just a bad idea.
Thomas.
-
Note to Sun employees: this is an EXTERNAL mailing list!
Info: send 'help' to java-interest-request@java.sun.com