On Wed, Mar 19, 2008 at 12:38:48PM -0400, Mark J. Reed wrote:
: For the record, I am opposed to any restriction on operator
: overloading that requires mathematical properties to hold.  ANYTHING
: is fair if you predeclare. Besides, there is nothing that inherently
: associates the "/" symbol with division - it's only an ASCII
: approximation of fraction notation.  I want to be able to define / as
: a path constructor and not give a flying flip that (path 2) * (path 3)
: / (path 5) - whatever the heck * might mean on paths - is not the same
: as (path 2) / (path 5) * (path 3).
: 
: The P in Perl stands for Practical, not Pedantic.

While I agree with the sentiment of not arbitrarily restricting
people from doing ugly things unless they ask for such restrictions,
I'd also like to point out that the desire to maintain consistent
symbolic distinctions is not limited to mathematicians.

The use of + in Python or << in C++ is, I think, primarily the
violation of a *linguistic* principle, not a mathematical principle.
The typical user already has a good notion of what the common operators
are, and what they mean.  So while drastically changing the meaning
of one of those operators may not be a disservice to the writer of
the code, it may well be a disservice to the reader.

Perl is about linguistics, and hence is more concerned with successful
communication than with pure mathematical platonics.

Larry

Reply via email to