Skip to content

Commit

Permalink
Gate async socket behind feature
Browse files Browse the repository at this point in the history
  • Loading branch information
evanrittenhouse committed Apr 24, 2024
1 parent 4565fb6 commit 9a0adbd
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
5 changes: 4 additions & 1 deletion dgram/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,11 @@ name = "dgram"
version = "0.1.0"
edition = "2021"

[features]
async = ["dep:tokio"]

[dependencies]
libc = "0.2.76"
nix = "0.26.2"
smallvec = { version = "1.10", features = ["union"] }
tokio = { version = "1.29", features = ["full", "test-util"] }
tokio = { version = "1.29", features = ["full", "test-util"], optional = true }
1 change: 1 addition & 0 deletions dgram/src/lib.rs
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
#[cfg(feature = "async")]
pub mod async_socket;
pub mod socket;
pub mod syscalls;

0 comments on commit 9a0adbd

Please sign in to comment.