Get an immutable borrow of the NumPy array # Panics Panics if the allocation backing the array is currently mutably borrowed. For a non-panicking variant, use [`try_readonly`][Self::try_readonly].
(&self)
| 1008 | /// |
| 1009 | /// For a non-panicking variant, use [`try_readonly`][Self::try_readonly]. |
| 1010 | fn readonly(&self) -> PyReadonlyArray<'py, T, D> |
| 1011 | where |
| 1012 | T: Element, |
| 1013 | D: Dimension, |
| 1014 | { |
| 1015 | self.try_readonly().unwrap() |
| 1016 | } |
| 1017 | |
| 1018 | /// Consume `self` into an mutable borrow of the NumPy array |
| 1019 | fn try_into_readwrite(self) -> Result<PyReadwriteArray<'py, T, D>, BorrowError> |