We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 3735956 commit 5c5f3ebCopy full SHA for 5c5f3eb
stdlib/sre_compile.pyi
@@ -2,14 +2,11 @@ from re import Pattern
2
from sre_constants import *
3
from sre_constants import _NamedIntConstant
4
from sre_parse import SubPattern
5
-from typing import Any, Final, Literal, overload
6
-from typing_extensions import TypeGuard
+from typing import Any, Final
+from typing_extensions import TypeIs
7
8
MAXCODE: Final[int]
9
10
def dis(code: list[_NamedIntConstant]) -> None: ...
11
-@overload
12
-def isstring(obj: str | bytes) -> Literal[True]: ...
13
14
-def isstring(obj: object) -> TypeGuard[str | bytes]: ...
+def isstring(obj: object) -> TypeIs[str | bytes]: ...
15
def compile(p: str | bytes | SubPattern, flags: int = 0) -> Pattern[Any]: ...
0 commit comments