@@ -21,12 +21,20 @@ class _Hash(object):
21
21
def hexdigest (self ) -> str : ...
22
22
def update (self , arg : _DataType ) -> None : ...
23
23
24
- def md5 (string : _DataType = ...) -> _Hash : ...
25
- def sha1 (string : _DataType = ...) -> _Hash : ...
26
- def sha224 (string : _DataType = ...) -> _Hash : ...
27
- def sha256 (string : _DataType = ...) -> _Hash : ...
28
- def sha384 (string : _DataType = ...) -> _Hash : ...
29
- def sha512 (string : _DataType = ...) -> _Hash : ...
24
+ if sys .version_info >= (3 , 8 ):
25
+ def md5 (string : _DataType = ...) -> _Hash : ...
26
+ def sha1 (string : _DataType = ...) -> _Hash : ...
27
+ def sha224 (string : _DataType = ...) -> _Hash : ...
28
+ def sha256 (string : _DataType = ...) -> _Hash : ...
29
+ def sha384 (string : _DataType = ...) -> _Hash : ...
30
+ def sha512 (string : _DataType = ...) -> _Hash : ...
31
+ else :
32
+ def md5 (__string : _DataType = ...) -> _Hash : ...
33
+ def sha1 (__string : _DataType = ...) -> _Hash : ...
34
+ def sha224 (__string : _DataType = ...) -> _Hash : ...
35
+ def sha256 (__string : _DataType = ...) -> _Hash : ...
36
+ def sha384 (__string : _DataType = ...) -> _Hash : ...
37
+ def sha512 (__string : _DataType = ...) -> _Hash : ...
30
38
31
39
def new (name : str , data : _DataType = ...) -> _Hash : ...
32
40
0 commit comments