diff --git a/stdlib/@python2/distutils/util.pyi b/stdlib/@python2/distutils/util.pyi index 6f5e755f5..935a695e5 100644 --- a/stdlib/@python2/distutils/util.pyi +++ b/stdlib/@python2/distutils/util.pyi @@ -1,4 +1,5 @@ from typing import Any, Callable, Mapping +from typing_extensions import Literal def get_platform() -> str: ... def convert_path(pathname: str) -> str: ... @@ -9,7 +10,7 @@ def split_quoted(s: str) -> list[str]: ... def execute( func: Callable[..., None], args: tuple[Any, ...], msg: str | None = ..., verbose: bool = ..., dry_run: bool = ... ) -> None: ... -def strtobool(val: str) -> bool: ... +def strtobool(val: str) -> Literal[0, 1]: ... def byte_compile( py_files: list[str], optimize: int = ..., diff --git a/stdlib/distutils/util.pyi b/stdlib/distutils/util.pyi index 03ee0185c..22d982e69 100644 --- a/stdlib/distutils/util.pyi +++ b/stdlib/distutils/util.pyi @@ -1,6 +1,7 @@ from _typeshed import StrPath from collections.abc import Callable, Container, Iterable, Mapping from typing import Any +from typing_extensions import Literal def get_platform() -> str: ... def convert_path(pathname: str) -> str: ... @@ -11,7 +12,7 @@ def split_quoted(s: str) -> list[str]: ... def execute( func: Callable[..., None], args: tuple[Any, ...], msg: str | None = ..., verbose: bool = ..., dry_run: bool = ... ) -> None: ... -def strtobool(val: str) -> bool: ... +def strtobool(val: str) -> Literal[0, 1]: ... def byte_compile( py_files: list[str], optimize: int = ...,