Skip to content

Commit

Permalink
Have cap-std re-export ipnet, which is part of its public API. (#302)
Browse files Browse the repository at this point in the history
  • Loading branch information
sunfishcode committed Mar 28, 2023
1 parent f2e65b9 commit 7d379e9
Show file tree
Hide file tree
Showing 7 changed files with 8 additions and 6 deletions.
1 change: 0 additions & 1 deletion cap-async-std/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@ arf-strings = { version = "0.7.0", optional = true }
async-std = { version = "1.10.0", features = ["attributes", "unstable"] }
cap-primitives = { path = "../cap-primitives", version = "^0.25.0" }
io-lifetimes = { version = "1.0.0", default-features = false, features = ["async-std"] }
ipnet = "2.3.0"
io-extras = { version = "0.17.0", features = ["use_async_std"] }
camino = { version = "1.0.5", optional = true }

Expand Down
3 changes: 2 additions & 1 deletion cap-async-std/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -50,5 +50,6 @@ pub use cap_primitives::{ambient_authority, AmbientAuthority};
// Re-export `async_std` to make it easy for users to depend on the same
// version we do, because we use its types in our public API.
pub use async_std;
// And this is also part of our public API
// And these are also part of our public API
pub use io_lifetimes;
pub use cap_primitives::ipnet;
2 changes: 1 addition & 1 deletion cap-async-std/src/net/pool.rs
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
use crate::net::{TcpListener, TcpStream, ToSocketAddrs, UdpSocket};
use async_std::{io, net};
use cap_primitives::net::NO_SOCKET_ADDRS;
use cap_primitives::AmbientAuthority;
use cap_primitives::{ipnet, AmbientAuthority};

/// A pool of network addresses.
///
Expand Down
2 changes: 2 additions & 0 deletions cap-primitives/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -28,3 +28,5 @@ pub mod time;
#[doc(hidden)]
pub use ambient_authority::ambient_authority_known_at_compile_time;
pub use ambient_authority::{ambient_authority, AmbientAuthority};
// This is part of our public API.
pub use ipnet;
1 change: 0 additions & 1 deletion cap-std/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@ rustdoc-args = ["--cfg=doc_cfg"]
[dependencies]
arf-strings = { version = "0.7.0", optional = true }
cap-primitives = { path = "../cap-primitives", version = "^1.0.7" }
ipnet = "2.3.0"
io-extras = "0.17.0"
io-lifetimes = { version = "1.0.0", default-features = false }
camino = { version = "1.0.5", optional = true }
Expand Down
3 changes: 2 additions & 1 deletion cap-std/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -48,5 +48,6 @@ pub mod time;
#[doc(hidden)]
pub use cap_primitives::ambient_authority_known_at_compile_time;
pub use cap_primitives::{ambient_authority, AmbientAuthority};
// And this is also part of our public API
// And these are also part of our public API
pub use cap_primitives::ipnet;
pub use io_lifetimes;
2 changes: 1 addition & 1 deletion cap-std/src/net/pool.rs
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
use crate::net::{SocketAddr, TcpListener, TcpStream, ToSocketAddrs, UdpSocket};
use cap_primitives::net::NO_SOCKET_ADDRS;
use cap_primitives::AmbientAuthority;
use cap_primitives::{ipnet, AmbientAuthority};
use std::time::Duration;
use std::{io, net};

Expand Down

0 comments on commit 7d379e9

Please sign in to comment.