[Python-ideas] Allow Profile() to be used as a context manager
David Townshend
aquavitae69 at gmail.com
Wed Jan 25 12:03:04 CET 2012
Oh yes, of course. Silly me!
On Wed, Jan 25, 2012 at 12:52 PM, Nick Coghlan <ncoghlan at gmail.com> wrote:
> On Wed, Jan 25, 2012 at 8:28 PM, David Townshend <aquavitae69 at gmail.com>
> wrote:
> > Would that stop the profiler between calles though? In Yuval's example,
> > wouldn't do_a_hard_but_i_dont_care_now_task be included in the profile
> > then?
>
> No, because the two profiling blocks aren't overlapping - the count
> drops to zero between them so the profiler will be disabled for that
> period.
>
> Cheers,
> Nick.
>
> --
> Nick Coghlan | ncoghlan at gmail.com | Brisbane, Australia
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/python-ideas/attachments/20120125/9c894e83/attachment.html>
More information about the Python-ideas
mailing list