Re: Overloading function calls

Steven D. Majewski (sdm7g@elvis.med.virginia.edu)
Sat, 28 May 1994 01:13:21 -0400

On May 27, 23:54, Tim Peters wrote:
( about overloaded operators and functions/methods )
>
> Is this a case where making the language _dumber_ would help more people
> than it hurt? I've hesitated to suggest a concrete alternative because I
> can't think of a reasonable one that's completely backward compatible.
> But many of the rules now aren't documented, and it's hard to believe
> they were all intentional anyway <wink>, so maybe backward compatibility
> isn't so important here?
>

"Coercion rules" is one of the few cases where I would vote to throw
backward compatability overboard if a better and more consistent
scheme were proposed. I have not made a whole lot of use of the
trickier aspects of overloading because of the problem of figuring
out how coerce works with the special cases of '*' ( for "seq * n"
or "n * seq" ) and some others. I have a bunch of code that I
have never posted or released because I could never quite figure
out how to write coercion rules that were bug free in all cases,
because I couldn't quite figure out what the rules ARE.

- Steve Majewski (804-982-0831) <sdm7g@Virginia.EDU>
- UVA Department of Molecular Physiology and Biological Physics