diff --git a/stdlib/2/_warnings.pyi b/stdlib/2/_warnings.pyi index 4f54529db..63fd9d486 100644 --- a/stdlib/2/_warnings.pyi +++ b/stdlib/2/_warnings.pyi @@ -1,11 +1,11 @@ -from typing import Any, List +from typing import Any, List, Optional, Type default_action = ... # type: str filters = ... # type: List[tuple] once_registry = ... # type: dict -def warn(message: Warning, category: type = ..., stacklevel: int = ...) -> None: ... -def warn_explicit(message: Warning, category: type, +def warn(message: Warning, category: Optional[Type[Warning]] = ..., stacklevel: int = ...) -> None: ... +def warn_explicit(message: Warning, category: Optional[Type[Warning]], filename: str, lineno: int, module: Any = ..., registry: dict = ..., module_globals: dict = ...) -> None: ... diff --git a/stdlib/3/_warnings.pyi b/stdlib/3/_warnings.pyi index b1f0431d3..4d890e51c 100644 --- a/stdlib/3/_warnings.pyi +++ b/stdlib/3/_warnings.pyi @@ -1,11 +1,11 @@ -from typing import Any, List +from typing import Any, List, Optional, Type _defaultaction = ... # type: str _onceregistry = ... # type: dict filters = ... # type: List[tuple] -def warn(message: Warning, category: type = ..., stacklevel: int = ...) -> None: ... -def warn_explicit(message: Warning, category: type, +def warn(message: Warning, category: Optional[Type[Warning]] = ..., stacklevel: int = ...) -> None: ... +def warn_explicit(message: Warning, category: Optional[Type[Warning]], filename: str, lineno: int, module: Any = ..., registry: dict = ..., module_globals: dict = ...) -> None: ...