summaryrefslogtreecommitdiffstats
path: root/Doc/library/asyncio-stream.rst
diff options
context:
space:
mode:
Diffstat (limited to 'Doc/library/asyncio-stream.rst')
-rw-r--r--Doc/library/asyncio-stream.rst3
1 files changed, 1 insertions, 2 deletions
diff --git a/Doc/library/asyncio-stream.rst b/Doc/library/asyncio-stream.rst
index 8f94ba7..f662e72 100644
--- a/Doc/library/asyncio-stream.rst
+++ b/Doc/library/asyncio-stream.rst
@@ -431,8 +431,7 @@ Simple example querying HTTP headers of the URL passed on the command line::
import urllib.parse
import sys
- @asyncio.coroutine
- def print_http_headers(url):
+ async def print_http_headers(url):
url = urllib.parse.urlsplit(url)
if url.scheme == 'https':
connect = asyncio.open_connection(url.hostname, 443, ssl=True)