mirror of
https://github.com/davidhalter/typeshed.git
synced 2025-12-22 11:51:28 +08:00
@@ -1,12 +1,15 @@
|
||||
from typing import Sequence, AnyStr, Text
|
||||
from typing import Sequence, AnyStr, Text, Union
|
||||
import sys
|
||||
|
||||
if sys.version_info >= (3, 0):
|
||||
def commonprefix(m: Sequence[str]) -> str: ...
|
||||
else:
|
||||
def commonprefix(m: Sequence[AnyStr]) -> AnyStr: ...
|
||||
|
||||
def exists(path: Text) -> bool: ...
|
||||
if sys.version_info >= (3, 6):
|
||||
from os import PathLike
|
||||
def exists(path: Union[AnyStr, PathLike[AnyStr]]) -> bool: ...
|
||||
else:
|
||||
def exists(path: Text) -> bool: ...
|
||||
def isfile(path: Text) -> bool: ...
|
||||
def isdir(s: Text) -> bool: ...
|
||||
def getsize(filename: Text) -> int: ...
|
||||
|
||||
Reference in New Issue
Block a user