|
1 | 1 | import sys |
2 | | -from _typeshed import SupportsGetItem |
| 2 | +from _typeshed import SupportsGetItem, SupportsMul, SupportsRMul |
3 | 3 | from collections.abc import Callable, Container, Iterable, MutableMapping, MutableSequence, Sequence |
4 | 4 | from operator import attrgetter as attrgetter, itemgetter as itemgetter, methodcaller as methodcaller |
5 | 5 | from typing import Any, AnyStr, Protocol, SupportsAbs, SupportsIndex, TypeVar, overload, type_check_only |
@@ -39,14 +39,6 @@ _SupportsComparison: TypeAlias = _SupportsDunderLE | _SupportsDunderGE | _Suppor |
39 | 39 | class _SupportsInversion(Protocol[_T_co]): |
40 | 40 | def __invert__(self) -> _T_co: ... |
41 | 41 |
|
42 | | -@type_check_only |
43 | | -class _SupportsMul(Protocol[_T_co, _T_contra]): |
44 | | - def __mul__(self, other: _T_contra, /) -> _T_co: ... |
45 | | - |
46 | | -@type_check_only |
47 | | -class _SupportsRMul(Protocol[_T_co, _T_contra]): |
48 | | - def __rmul__(self, other: _T_contra, /) -> _T_co: ... |
49 | | - |
50 | 42 | @type_check_only |
51 | 43 | class _SupportsNeg(Protocol[_T_co]): |
52 | 44 | def __neg__(self) -> _T_co: ... |
@@ -76,9 +68,9 @@ def invert(a: _SupportsInversion[_T_co], /) -> _T_co: ... |
76 | 68 | def lshift(a, b, /): ... |
77 | 69 | def mod(a, b, /): ... |
78 | 70 | @overload |
79 | | -def mul(a: _SupportsMul[_T_co, _T_contra], b: _T_contra, /) -> _T_co: ... |
| 71 | +def mul(a: SupportsMul[_T_contra, _T_co], b: _T_contra, /) -> _T_co: ... |
80 | 72 | @overload |
81 | | -def mul(a: _T_contra, b: _SupportsRMul[_T_co, _T_contra], /) -> _T_co: ... |
| 73 | +def mul(a: _T_contra, b: SupportsRMul[_T_contra, _T_co], /) -> _T_co: ... |
82 | 74 | def matmul(a, b, /): ... |
83 | 75 | def neg(a: _SupportsNeg[_T_co], /) -> _T_co: ... |
84 | 76 | def or_(a, b, /): ... |
|
0 commit comments