polymorphism w/out signatures?
Bryan Castillo
rook_5150 at yahoo.com
Fri May 7 00:16:17 EDT 2004
Donn Cave <donn at u.washington.edu> wrote in message news:<donn-0FC5DB.15041506052004 at nntp6.u.washington.edu>...
> In article <997a06e0.0405061128.6768676d at posting.google.com>,
> pugnatio2 at yahoo.com wrote:
>
> > What's the standard way to implement polymorphic behavior in a python
> > method, given that method arguments can't declare their types as
> > they're being passed in, and method definitions don't have signatures?
> >
<snip>
> On the other hand, if you want to support a string as an single
> value instead of a list or tuple of values, then you're not
> really talking about polymorphism here anyway. When a function
> decides to support various unrelated types for a particular
> parameter, I don't know what you call that, but it isn't
> polymorphism in any useful sense.
The original poster is talking about function/method overloading as
you have in C++ or Java.
<snip>
More information about the Python-list
mailing list