Skip to content

Commit

Permalink
Replace a use of libc::c_void with the std version (#4572)
Browse files Browse the repository at this point in the history
  • Loading branch information
alex authored Sep 21, 2024
1 parent 6b3f887 commit df07100
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions src/types/capsule.rs
Original file line number Diff line number Diff line change
Expand Up @@ -194,8 +194,8 @@ pub trait PyCapsuleMethods<'py>: crate::sealed::Sealed {
/// # Example
///
/// ```
/// use std::os::raw::c_void;
/// use std::sync::mpsc::{channel, Sender};
/// use libc::c_void;
/// use pyo3::{prelude::*, types::PyCapsule};
///
/// let (tx, rx) = channel::<String>();
Expand Down Expand Up @@ -357,13 +357,12 @@ fn name_ptr_ignore_error(slf: &Bound<'_, PyCapsule>) -> *const c_char {

#[cfg(test)]
mod tests {
use libc::c_void;

use crate::prelude::PyModule;
use crate::types::capsule::PyCapsuleMethods;
use crate::types::module::PyModuleMethods;
use crate::{types::PyCapsule, Py, PyResult, Python};
use std::ffi::CString;
use std::os::raw::c_void;
use std::sync::mpsc::{channel, Sender};

#[test]
Expand Down

0 comments on commit df07100

Please sign in to comment.