MCPcopy Create free account
hub / github.com/numpy/numpy / __radd__

Method __radd__

numpy/array_api/_array_object.py:800–809  ·  view source on GitHub ↗

Performs the operation __radd__.

(self: Array, other: Union[int, float, Array], /)

Source from the content-addressed store, hash-verified

798 return self
799
800 def __radd__(self: Array, other: Union[int, float, Array], /) -> Array:
801 """
802 Performs the operation __radd__.
803 """
804 other = self._check_allowed_dtypes(other, "numeric", "__radd__")
805 if other is NotImplemented:
806 return other
807 self, other = self._normalize_two_args(self, other)
808 res = self._array.__radd__(other._array)
809 return self.__class__._new(res)
810
811 def __iand__(self: Array, other: Union[int, bool, Array], /) -> Array:
812 """

Callers

nothing calls this directly

Calls 3

_check_allowed_dtypesMethod · 0.95
_normalize_two_argsMethod · 0.95
_newMethod · 0.80

Tested by

no test coverage detected