One Python 2.1 idea

Alex Martelli aleaxit at yahoo.com
Tue Dec 26 04:03:41 EST 2000


<rturpin at my-deja.com> wrote in message news:9292tn$jka$1 at nnrp1.deja.com...
    [snip]
> Second, a question. Consider the invocation of a method,
> such as:
>
>     x.foo()
>
> Does this really cause the lookup of the string "foo"
> in x's namespace dictionary? The first time? Every time?

Yes, and yes.  No implicit caching.

> Is this also the case when data members are accessed?

Yes once more.


Alex






More information about the Python-list mailing list