]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
Fix: typo (Indention) (GH-99904)
authorjarrodcolburn <jcourtlandcolburn@gmail.com>
Mon, 12 Dec 2022 12:25:22 +0000 (06:25 -0600)
committerGitHub <noreply@github.com>
Mon, 12 Dec 2022 12:25:22 +0000 (04:25 -0800)
Example needed to be indented. Was trying to call a context manger `pr` (from ` with cProfile.Profile() as pr:`) wot perform ` pr.print_stats()` once it had already exited.

Automerge-Triggered-By: GH:AlexWaygood
Doc/library/profile.rst

index 2d95096f4cb83a895cb4bb20953ab17946ebf67d..c2189e02656c7af14f4ee00aca8b23fb39571ed6 100644 (file)
@@ -274,7 +274,7 @@ functions:
       with cProfile.Profile() as pr:
           # ... do something ...
 
-      pr.print_stats()
+          pr.print_stats()
 
    .. versionchanged:: 3.8
       Added context manager support.