[issue5633] fix for timeit when the statment is a string and the setup is not (and tests)
Raymond Hettinger
report at bugs.python.org
Tue Mar 31 23:17:27 CEST 2009
Raymond Hettinger <rhettinger at users.sourceforge.net> added the comment:
Georg, this was your patch: http://bugs.python.org/issue1533909
I don't think it should have been accepted so readily. It is not
harmonious with all of the other proposals for improving timeit.
No that it is out in the wild, I think all you can do is fix-up the docs.
Also, the inner template function should have a func=func argument so
that the func() call is localized. This affects the timings. Part of
the concept of the module is to make the surrounding timing apparatus be
as light-weight as possible so that the timings reflect the thing being
timed without being obscured by the overhead of the timing module itself.
----------
assignee: rhettinger -> georg.brandl
nosy: +georg.brandl
_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue5633>
_______________________________________
More information about the Python-bugs-list
mailing list