Skip to content

Commit

Permalink
Include #![feature(ptr_fn_addr_eq)] for non-nightly builds
Browse files Browse the repository at this point in the history
  • Loading branch information
clin1234 authored Dec 22, 2024
1 parent dd1c2d9 commit 6c352a6
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/impl_/pymethods.rs
Original file line number Diff line number Diff line change
Expand Up @@ -21,10 +21,11 @@ use std::panic::{catch_unwind, AssertUnwindSafe};
use std::ptr::null_mut;

#[cfg(feature = "nightly")]
// #![feature(ptr_fn_addr_eq)]
#![feature(ptr_fn_addr_eq)]
use std::ptr::fn_addr_eq;

#[cfg(not(feature = "nightly"))]
#![feature(ptr_fn_addr_eq)]
use std::marker::FnPtr;
pub fn fn_addr_eq<T: FnPtr, U: FnPtr>(f: T, g: U) -> bool {
f.addr() == g.addr()
Expand Down

0 comments on commit 6c352a6

Please sign in to comment.