Use new method to implement old

This commit is contained in:
Blaž Šnuderl 2024-02-05 08:03:03 +01:00
parent 8388b14369
commit 1fd0aa2b19
2 changed files with 2 additions and 2 deletions

View File

@ -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.

View File

@ -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.