Skip to content

Commit

Permalink
clean up rustdocs
Browse files Browse the repository at this point in the history
  • Loading branch information
“ramfox” committed Jan 10, 2025
1 parent c23f1eb commit 96aa2a5
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions iroh-base/src/ip_mapped_addrs.rs
Original file line number Diff line number Diff line change
Expand Up @@ -17,16 +17,16 @@ pub struct IpMappedAddrError(String);

/// A mirror for the `NodeIdMappedAddr`, mapping a fake Ipv6 address with an actual IP address.
///
/// You can consider this as nothing more than a lookup key for an IP the [`MagicSock`] knows
/// You can consider this as nothing more than a lookup key for an IP that iroh's magicsocket knows
/// about.
///
/// And in our QUIC-facing socket APIs like [`AsyncUdpSocket`] it
/// And in our QUIC-facing socket APIs like iroh's `AsyncUdpSocket` it
/// comes in as the inner [`SocketAddr`], in those interfaces we have to be careful to do
/// the conversion to this type.
#[derive(Debug, Copy, Clone, PartialEq, Eq, Hash, Ord, PartialOrd)]
pub struct IpMappedAddr(pub(crate) SocketAddr);

/// Counter to always generate unique addresses for [`NodeIdMappedAddr`].
/// Counter to always generate unique addresses for `NodeIdMappedAddr`.
static IP_ADDR_COUNTER: AtomicU64 = AtomicU64::new(1);

impl IpMappedAddr {
Expand Down Expand Up @@ -90,7 +90,7 @@ impl std::fmt::Display for IpMappedAddr {
}

#[derive(Debug, Clone)]
/// A Map of [`IpMappedAddrs`] to [`SocketAddrs`]
/// A Map of [`IpMappedAddrs`] to [`SocketAddr`]
pub struct IpMappedAddrs(Arc<std::sync::Mutex<BTreeMap<IpMappedAddr, SocketAddr>>>);

impl IpMappedAddrs {
Expand Down

0 comments on commit 96aa2a5

Please sign in to comment.