Correct str.maketrans and collections.UserString.maketrans (#9611)

This commit is contained in:
Alex Waygood
2023-01-29 19:45:08 +00:00
committed by GitHub
parent 2ffd867f25
commit dd3aedd133
3 changed files with 5 additions and 8 deletions

View File

@@ -551,7 +551,10 @@ class str(Sequence[str]):
def maketrans(__x: dict[int, _T] | dict[str, _T] | dict[str | int, _T]) -> dict[int, _T]: ...
@staticmethod
@overload
def maketrans(__x: str, __y: str, __z: str | None = ...) -> dict[int, int | None]: ...
def maketrans(__x: str, __y: str) -> dict[int, int]: ...
@staticmethod
@overload
def maketrans(__x: str, __y: str, __z: str) -> dict[int, int | None]: ...
@overload
def __add__(self: LiteralString, __s: LiteralString) -> LiteralString: ...
@overload