Why the 'self' argument?

Terry Reedy tjreedy at udel.edu
Mon Sep 8 22:49:35 EDT 2003


"John Roth" <newsgroups at jhrothjr.com> wrote in message
news:vlpr14kfehrn46 at news.supernews.com...
> It's not a simple thing to do, and the fact that ML
> family languages manage to do it without having
> to have explicit type declarations (well, most of the
> time anyway) is a major achievement, IMO.

As I remember, part of the cost (for ML at least) is having separate
operators for ints and floats.  Bye bye generic functions.  I don't
remember if there was any escape from the type straightjacket (like
#define max(a,b) ... in C).  And one has to adjust to and feel
comfortable enough with the view that multiparam functions are a
composition of single param functions.  But I agree that the type
inferencing is an interesting achievement.

Terry J. Reedy






More information about the Python-list mailing list