Skip to content

Commit 2d146e7

Browse files
authored
Use PEP 570 syntax in comments (#11552)
1 parent 470a13a commit 2d146e7

File tree

3 files changed

+3
-3
lines changed

3 files changed

+3
-3
lines changed

stdlib/_decimal.pyi

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -182,7 +182,7 @@ class Context:
182182
# even settable attributes like `prec` and `rounding`,
183183
# but that's inexpressable in the stub.
184184
# Type checkers either ignore it or misinterpret it
185-
# if you add a `def __delattr__(self, __name: str) -> NoReturn` method to the stub
185+
# if you add a `def __delattr__(self, name: str, /) -> NoReturn` method to the stub
186186
prec: int
187187
rounding: str
188188
Emin: int

stdlib/_typeshed/dbapi.pyi

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ class DBAPICursor(Protocol):
2323
@property
2424
def rowcount(self) -> int: ...
2525
# optional:
26-
# def callproc(self, __procname: str, __parameters: Sequence[Any] = ...) -> Sequence[Any]: ...
26+
# def callproc(self, procname: str, parameters: Sequence[Any] = ..., /) -> Sequence[Any]: ...
2727
def close(self) -> object: ...
2828
def execute(self, operation: str, parameters: Sequence[Any] | Mapping[str, Any] = ..., /) -> object: ...
2929
def executemany(self, operation: str, seq_of_parameters: Sequence[Sequence[Any]], /) -> object: ...

stdlib/zipfile/__init__.pyi

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ class _ZipStream(Protocol):
4444
# The following methods are optional:
4545
# def seekable(self) -> bool: ...
4646
# def tell(self) -> int: ...
47-
# def seek(self, __n: int) -> object: ...
47+
# def seek(self, n: int, /) -> object: ...
4848

4949
# Stream shape as required by _EndRecData() and _EndRecData64().
5050
class _SupportsReadSeekTell(Protocol):

0 commit comments

Comments
 (0)