diff options
author | Bas van Beek <b.f.van.beek@vu.nl> | 2022-01-24 17:17:35 +0100 |
---|---|---|
committer | Bas van Beek <b.f.van.beek@vu.nl> | 2022-01-24 17:29:03 +0100 |
commit | 5264dc220dc208e533bdbdcafa9f4f06ddb04aab (patch) | |
tree | 5c3035d8acba53fe3a4efe9600f7a88eceefa055 /numpy/core/numeric.pyi | |
parent | 6218e76bc590e9253ed8d4c4b18c74aa81332b15 (diff) | |
download | numpy-5264dc220dc208e533bdbdcafa9f4f06ddb04aab.tar.gz |
MAINT: Create the `_DTypeLike` type-alias in `numpy.typing`
Represents a subset of `npt.DTypeLike` that can be parametrized w.r.t. `np.generic`
Diffstat (limited to 'numpy/core/numeric.pyi')
-rw-r--r-- | numpy/core/numeric.pyi | 8 |
1 files changed, 1 insertions, 7 deletions
diff --git a/numpy/core/numeric.pyi b/numpy/core/numeric.pyi index d5e28d24c..367a2bff8 100644 --- a/numpy/core/numeric.pyi +++ b/numpy/core/numeric.pyi @@ -1,7 +1,6 @@ from collections.abc import Callable, Sequence from typing import ( Any, - Union, overload, TypeVar, Literal, @@ -34,7 +33,7 @@ from numpy.typing import ( NDArray, DTypeLike, _ShapeLike, - _SupportsDType, + _DTypeLike, _FiniteNestedSequence, _SupportsArray, _SupportsArrayFunc, @@ -52,11 +51,6 @@ _T = TypeVar("_T") _SCT = TypeVar("_SCT", bound=generic) _ArrayType = TypeVar("_ArrayType", bound=NDArray[Any]) -_DTypeLike = Union[ - dtype[_SCT], - type[_SCT], - _SupportsDType[dtype[_SCT]], -] _ArrayLike = _FiniteNestedSequence[_SupportsArray[dtype[_SCT]]] _CorrelateMode = Literal["valid", "same", "full"] |