Skip to content

Commit fb3c76f

Browse files
authored
Merge pull request #24615 from charris/backport-24611
TYP: Add the missing ``casting`` keyword to ``np.clip``
2 parents 790bfc7 + 7404e37 commit fb3c76f

File tree

1 file changed

+7
-6
lines changed

1 file changed

+7
-6
lines changed

numpy/core/fromnumeric.pyi

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@ from numpy import (
2121
_PartitionKind,
2222
_SortKind,
2323
_SortSide,
24+
_CastingKind,
2425
)
2526
from numpy._typing import (
2627
DTypeLike,
@@ -392,7 +393,7 @@ def clip(
392393
order: _OrderKACF = ...,
393394
subok: bool = ...,
394395
signature: str | tuple[None | str, ...] = ...,
395-
extobj: list[Any] = ...,
396+
casting: _CastingKind = ...,
396397
) -> _SCT: ...
397398
@overload
398399
def clip(
@@ -406,7 +407,7 @@ def clip(
406407
order: _OrderKACF = ...,
407408
subok: bool = ...,
408409
signature: str | tuple[None | str, ...] = ...,
409-
extobj: list[Any] = ...,
410+
casting: _CastingKind = ...,
410411
) -> Any: ...
411412
@overload
412413
def clip(
@@ -420,7 +421,7 @@ def clip(
420421
order: _OrderKACF = ...,
421422
subok: bool = ...,
422423
signature: str | tuple[None | str, ...] = ...,
423-
extobj: list[Any] = ...,
424+
casting: _CastingKind = ...,
424425
) -> NDArray[_SCT]: ...
425426
@overload
426427
def clip(
@@ -434,7 +435,7 @@ def clip(
434435
order: _OrderKACF = ...,
435436
subok: bool = ...,
436437
signature: str | tuple[None | str, ...] = ...,
437-
extobj: list[Any] = ...,
438+
casting: _CastingKind = ...,
438439
) -> NDArray[Any]: ...
439440
@overload
440441
def clip(
@@ -448,7 +449,7 @@ def clip(
448449
order: _OrderKACF = ...,
449450
subok: bool = ...,
450451
signature: str | tuple[None | str, ...] = ...,
451-
extobj: list[Any] = ...,
452+
casting: _CastingKind = ...,
452453
) -> Any: ...
453454
@overload
454455
def clip(
@@ -462,7 +463,7 @@ def clip(
462463
order: _OrderKACF = ...,
463464
subok: bool = ...,
464465
signature: str | tuple[None | str, ...] = ...,
465-
extobj: list[Any] = ...,
466+
casting: _CastingKind = ...,
466467
) -> _ArrayType: ...
467468

468469
@overload

0 commit comments

Comments
 (0)