Use new method to implement old
This commit is contained in:
parent
8388b14369
commit
1fd0aa2b19
|
@ -18,7 +18,7 @@ impl PyEllipsis {
|
|||
)]
|
||||
#[inline]
|
||||
pub fn get(py: Python<'_>) -> &PyEllipsis {
|
||||
unsafe { py.from_borrowed_ptr(ffi::Py_Ellipsis()) }
|
||||
Self::get_bound(py).into_gil_ref()
|
||||
}
|
||||
|
||||
/// Returns the `Ellipsis` object.
|
||||
|
|
|
@ -18,7 +18,7 @@ impl PyNotImplemented {
|
|||
)]
|
||||
#[inline]
|
||||
pub fn get(py: Python<'_>) -> &PyNotImplemented {
|
||||
unsafe { py.from_borrowed_ptr(ffi::Py_NotImplemented()) }
|
||||
Self::get_bound(py).into_gil_ref()
|
||||
}
|
||||
|
||||
/// Returns the `NotImplemented` object.
|
||||
|
|
Loading…
Reference in New Issue