Sitelet https://github.com/python/typing_extensions/pull/174/files
Skip to content
Merged
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
8 changes: 7 additions & 1 deletion src/typing_extensions.py
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,13 @@
# The functions below are modified copies of typing internal helpers.
# They are needed by _ProtocolMeta and they provide support for PEP 646.

_marker = object()

class _Sentinel:
Comment thread
AlexWaygood marked this conversation as resolved.
def __repr__(self):
return "<sentinel>"


_marker = _Sentinel()


def _check_generic(cls, parameters, elen=_marker):
Expand Down