Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 19 additions & 1 deletion third_party/2and3/mypy_extensions.pyi
Original file line number Diff line number Diff line change
@@ -1,6 +1,24 @@
from typing import Dict, Type, TypeVar
from typing import Dict, Type, TypeVar, Optional, Any

T = TypeVar('T')


def TypedDict(typename: str, fields: Dict[str, Type[T]]) -> Type[dict]: ...

class Arg(object):
def __init__(name: Optional[str]=...,
typ: Type[T]=...,
keyword_only: Optional[bool]=...) -> None:
...

class DefaultArg(object):
def __init__(name: Optional[str]=...,
typ: Type[T]=...,
keyword_only: Optional[bool]=...) -> None:
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oops these actually shouldn't be optional. What I get for reviewing my own code.

...

class StarArg(object):
def __init__(typ: Type[T]=...) -> None: ...

class KwArg(object):
def __init__(typ: Type[T]=...) -> None: ...