mirror of
https://github.com/python/cpython
synced 2024-10-03 00:45:15 +00:00
Typing docs: normalize some indents in code examples (#120912)
This commit is contained in:
parent
f4ddaa3967
commit
0b918e81c1
|
@ -97,8 +97,9 @@ Type aliases are useful for simplifying complex type signatures. For example::
|
|||
# The static type checker will treat the previous type signature as
|
||||
# being exactly equivalent to this one.
|
||||
def broadcast_message(
|
||||
message: str,
|
||||
servers: Sequence[tuple[tuple[str, int], dict[str, str]]]) -> None:
|
||||
message: str,
|
||||
servers: Sequence[tuple[tuple[str, int], dict[str, str]]]
|
||||
) -> None:
|
||||
...
|
||||
|
||||
The :keyword:`type` statement is new in Python 3.12. For backwards
|
||||
|
@ -1871,8 +1872,8 @@ without the dedicated syntax, as documented below.
|
|||
of ``*args``::
|
||||
|
||||
def call_soon[*Ts](
|
||||
callback: Callable[[*Ts], None],
|
||||
*args: *Ts
|
||||
callback: Callable[[*Ts], None],
|
||||
*args: *Ts
|
||||
) -> None:
|
||||
...
|
||||
callback(*args)
|
||||
|
|
Loading…
Reference in a new issue