From 4dd82194f4a0e48a94191655e571b3aad1c4a22a Mon Sep 17 00:00:00 2001 From: Zbigniew Siciarz Date: Thu, 25 Nov 2021 13:30:48 +0100 Subject: bpo-45568: Actually use @asynccontextmanager in usage example (GH-29151) Automerge-Triggered-By: GH:asvetlov --- Doc/library/contextlib.rst | 2 ++ 1 file changed, 2 insertions(+) diff --git a/Doc/library/contextlib.rst b/Doc/library/contextlib.rst index a800a0b..bb93088 100644 --- a/Doc/library/contextlib.rst +++ b/Doc/library/contextlib.rst @@ -130,7 +130,9 @@ Functions and classes provided: either as decorators or with :keyword:`async with` statements:: import time + from contextlib import asynccontextmanager + @asynccontextmanager async def timeit(): now = time.monotonic() try: -- cgit v0.12