Skip to content

Commit

Permalink
bugfix: Fix check_cfg warning on nightly
Browse files Browse the repository at this point in the history
Signed-off-by: John Nunley <dev@notgull.net>
  • Loading branch information
notgull committed May 29, 2024
1 parent e740947 commit 7fe9731
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
3 changes: 3 additions & 0 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,9 @@ keywords = ["mio", "epoll", "kqueue", "iocp"]
categories = ["asynchronous", "network-programming", "os"]
exclude = ["/.*"]

[lints.rust]
unexpected_cfgs = { level = "warn", check-cfg = ['cfg(polling_test_poll_backend)'] }

[[bench]]
name = "io"
harness = false
Expand Down
2 changes: 0 additions & 2 deletions src/os/unix.rs
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
//! Functionality that is only available for `unix` platforms.

#[cfg(not(async_io_no_io_safety))]
use std::os::unix::io::BorrowedFd;

/// Get a file descriptor that can be used to wait for readiness in an external runtime.
Expand Down Expand Up @@ -41,7 +40,6 @@ use std::os::unix::io::BorrowedFd;
/// # pub fn register(_: BorrowedFd<'_>) {}
/// # }
/// ```
#[cfg(not(async_io_no_io_safety))]
pub fn reactor_fd() -> Option<BorrowedFd<'static>> {
cfg_if::cfg_if! {
if #[cfg(all(
Expand Down

0 comments on commit 7fe9731

Please sign in to comment.