From 8afa8245bb40a13d004bf41158142bf695e3a003 Mon Sep 17 00:00:00 2001 From: Guido van Rossum Date: Thu, 22 Jun 1995 18:52:35 +0000 Subject: functions don't have a __name__ attribute --- Lib/profile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Lib/profile.py b/Lib/profile.py index 35ed63e..f41a8ae 100755 --- a/Lib/profile.py +++ b/Lib/profile.py @@ -406,7 +406,7 @@ class Profile: # This method is more useful to profile a single function call. def runcall(self, func, *args): - self.set_cmd(func.__name__) + self.set_cmd(`func`) sys.setprofile(self.trace_dispatch) try: apply(func, args) -- cgit v0.12