mirror of
https://github.com/davidhalter/typeshed.git
synced 2025-12-20 02:41:16 +08:00
Make cgi.escape() polymorphic in Python 2 (#1098)
This commit is contained in:
committed by
Jelle Zijlstra
parent
604839c3a2
commit
16074c1e66
@@ -1,5 +1,5 @@
|
||||
import sys
|
||||
from typing import Any, Dict, IO, Iterable, List, Mapping, Optional, Tuple, TypeVar, Union
|
||||
from typing import Any, AnyStr, Dict, IO, Iterable, List, Mapping, Optional, Tuple, TypeVar, Union
|
||||
|
||||
_T = TypeVar('_T', bound=FieldStorage)
|
||||
|
||||
@@ -14,7 +14,10 @@ def print_environ(environ: Mapping[str, str] = ...) -> None: ...
|
||||
def print_form(form: Dict[str, Any]) -> None: ...
|
||||
def print_directory() -> None: ...
|
||||
def print_environ_usage() -> None: ...
|
||||
def escape(s: str, quote: bool = ...) -> str: ...
|
||||
if sys.version_info >= (3, 0):
|
||||
def escape(s: str, quote: bool = ...) -> str: ...
|
||||
else:
|
||||
def escape(s: AnyStr, quote: bool = ...) -> AnyStr: ...
|
||||
|
||||
|
||||
class MiniFieldStorage:
|
||||
|
||||
Reference in New Issue
Block a user