Counting the number of call of a function

Laurent Claessens moky.math at gmail.com
Fri Sep 30 11:13:14 CEST 2011


> The keys of globals() are the _names_. You're giving it the function
> itself.

Ow, ok. I didn't caught it. I understand now.

  > A decorator would be better.

Yes. I keep the solution with
foo=Wraper(foo)

Thanks a lot all !
Laurent




More information about the Python-list mailing list