mirror of
https://github.com/davidhalter/typeshed.git
synced 2026-08-01 13:40:23 +08:00
Add @type_check_only to stub-only private classes in stdlib (#14512)
This commit is contained in:
+2
-1
@@ -5,7 +5,7 @@ from builtins import list as _list # "list" conflicts with method name
|
||||
from collections.abc import Callable, Container, Mapping, MutableMapping
|
||||
from reprlib import Repr
|
||||
from types import MethodType, ModuleType, TracebackType
|
||||
from typing import IO, Any, AnyStr, Final, NoReturn, Protocol, TypeVar
|
||||
from typing import IO, Any, AnyStr, Final, NoReturn, Protocol, TypeVar, type_check_only
|
||||
from typing_extensions import TypeGuard, deprecated
|
||||
|
||||
__all__ = ["help"]
|
||||
@@ -17,6 +17,7 @@ __date__: Final[str]
|
||||
__version__: Final[str]
|
||||
__credits__: Final[str]
|
||||
|
||||
@type_check_only
|
||||
class _Pager(Protocol):
|
||||
def __call__(self, text: str, title: str = "") -> None: ...
|
||||
|
||||
|
||||
Reference in New Issue
Block a user