summaryrefslogtreecommitdiff
path: root/numpy/typing/_array_like.py
diff options
context:
space:
mode:
authorBas van Beek <43369155+BvB93@users.noreply.github.com>2021-06-05 23:35:11 +0200
committerBas van Beek <43369155+BvB93@users.noreply.github.com>2021-06-05 23:35:11 +0200
commit7162dc3c9f3cc02434c50dfb4e55b790453c00a4 (patch)
treea1e42466dc626dc78986bec79bb8c0c9ff50bbe8 /numpy/typing/_array_like.py
parentf23ade75773f5e94c030c40cae5b6e081b650205 (diff)
downloadnumpy-7162dc3c9f3cc02434c50dfb4e55b790453c00a4.tar.gz
REV,BUG: Replace `NotImplemented` with `typing.Any`
Diffstat (limited to 'numpy/typing/_array_like.py')
-rw-r--r--numpy/typing/_array_like.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/numpy/typing/_array_like.py b/numpy/typing/_array_like.py
index 2b823ecc0..187dfb96a 100644
--- a/numpy/typing/_array_like.py
+++ b/numpy/typing/_array_like.py
@@ -1,7 +1,7 @@
from __future__ import annotations
import sys
-from typing import Any, Sequence, TYPE_CHECKING, Union, TypeVar
+from typing import Any, Sequence, TYPE_CHECKING, Union, TypeVar, Generic
from numpy import (
ndarray,
@@ -43,7 +43,7 @@ if TYPE_CHECKING or _HAS_TYPING_EXTENSIONS:
class _SupportsArray(Protocol[_DType_co]):
def __array__(self) -> ndarray[Any, _DType_co]: ...
else:
- _SupportsArray = Any
+ class _SupportsArray(Generic[_DType_co]): ...
# TODO: Wait for support for recursive types
_NestedSequence = Union[