| 1 |
from typing import Protocol, TypeVar, Iterable |
| 2 |
|
| 3 |
_KT = TypeVar("_KT") |
| 4 |
_VT_co = TypeVar("_VT_co", covariant=True) |
| 5 |
|
| 6 |
class SupportsKeysAndGetItem(Protocol[_KT, _VT_co]): |
| 7 |
def keys(self) -> Iterable[_KT]: pass |
| 8 |
def __getitem__(self, __key: _KT) -> _VT_co: pass |