File tree Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -101,7 +101,7 @@ pub fn safe_repr(v: &PyAny) -> Cow<str> {
101
101
102
102
/// Extract an i64 from a python object more quickly, see
103
103
/// https://github.com/PyO3/pyo3/pull/3742#discussion_r1451763928
104
- #[ cfg( not( any( target_pointer_width = "32" , target_os = " windows" ) ) ) ]
104
+ #[ cfg( not( any( target_pointer_width = "32" , windows, PyPy ) ) ) ]
105
105
pub fn extract_i64 ( obj : & PyAny ) -> Option < i64 > {
106
106
let val = unsafe { ffi:: PyLong_AsLong ( obj. as_ptr ( ) ) } ;
107
107
if val == -1 && PyErr :: occurred ( obj. py ( ) ) {
@@ -112,7 +112,7 @@ pub fn extract_i64(obj: &PyAny) -> Option<i64> {
112
112
}
113
113
}
114
114
115
- #[ cfg( any( target_pointer_width = "32" , target_os = " windows" ) ) ]
115
+ #[ cfg( any( target_pointer_width = "32" , windows, PyPy ) ) ]
116
116
pub fn extract_i64 ( v : & PyAny ) -> Option < i64 > {
117
117
if v. is_instance_of :: < pyo3:: types:: PyInt > ( ) {
118
118
v. extract ( ) . ok ( )
You can’t perform that action at this time.
0 commit comments