bpo-39231: correct tutorial annotations section (GH-25029)

(cherry picked from commit a53e9a7cf5)

Co-authored-by: Irit Katriel <iritkatriel@yahoo.com>
This commit is contained in:
Miss Islington (bot) 2021-03-27 10:43:08 -07:00 committed by GitHub
parent c84e769c2b
commit 7990072999
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -866,7 +866,7 @@ function. Parameter annotations are defined by a colon after the parameter name
by an expression evaluating to the value of the annotation. Return annotations are
defined by a literal ``->``, followed by an expression, between the parameter
list and the colon denoting the end of the :keyword:`def` statement. The
following example has a positional argument, a keyword argument, and the return
following example has a required argument, an optional argument, and the return
value annotated::
>>> def f(ham: str, eggs: str = 'eggs') -> str: