mirror of
https://github.com/davidhalter/typeshed.git
synced 2026-05-09 06:46:18 +08:00
[glob] Deprecate glob0 and glob1 functions (#14477)
This commit is contained in:
+10
-2
@@ -2,14 +2,22 @@ import sys
|
||||
from _typeshed import StrOrBytesPath
|
||||
from collections.abc import Iterator, Sequence
|
||||
from typing import AnyStr
|
||||
from typing_extensions import deprecated
|
||||
|
||||
__all__ = ["escape", "glob", "iglob"]
|
||||
|
||||
if sys.version_info >= (3, 13):
|
||||
__all__ += ["translate"]
|
||||
|
||||
def glob0(dirname: AnyStr, pattern: AnyStr) -> list[AnyStr]: ...
|
||||
def glob1(dirname: AnyStr, pattern: AnyStr) -> list[AnyStr]: ...
|
||||
if sys.version_info >= (3, 10):
|
||||
@deprecated("Will be removed in Python 3.15; Use `glob.glob` and pass *root_dir* argument instead.")
|
||||
def glob0(dirname: AnyStr, pattern: AnyStr) -> list[AnyStr]: ...
|
||||
@deprecated("Will be removed in Python 3.15; Use `glob.glob` and pass *root_dir* argument instead.")
|
||||
def glob1(dirname: AnyStr, pattern: AnyStr) -> list[AnyStr]: ...
|
||||
|
||||
else:
|
||||
def glob0(dirname: AnyStr, pattern: AnyStr) -> list[AnyStr]: ...
|
||||
def glob1(dirname: AnyStr, pattern: AnyStr) -> list[AnyStr]: ...
|
||||
|
||||
if sys.version_info >= (3, 11):
|
||||
def glob(
|
||||
|
||||
Reference in New Issue
Block a user