|
@@ -43,9 +43,10 @@ pub enum RecvError {
|
|
|
/// more details.
|
|
|
///
|
|
|
/// [IcmpSocket::bind]: struct.IcmpSocket.html#method.bind
|
|
|
-#[derive(Debug, PartialEq, Eq, PartialOrd, Ord, Clone, Copy)]
|
|
|
+#[derive(Debug, Default, PartialEq, Eq, PartialOrd, Ord, Clone, Copy)]
|
|
|
#[cfg_attr(feature = "defmt", derive(defmt::Format))]
|
|
|
pub enum Endpoint {
|
|
|
+ #[default]
|
|
|
Unspecified,
|
|
|
Ident(u16),
|
|
|
Udp(IpListenEndpoint),
|
|
@@ -61,12 +62,6 @@ impl Endpoint {
|
|
|
}
|
|
|
}
|
|
|
|
|
|
-impl Default for Endpoint {
|
|
|
- fn default() -> Endpoint {
|
|
|
- Endpoint::Unspecified
|
|
|
- }
|
|
|
-}
|
|
|
-
|
|
|
/// An ICMP packet metadata.
|
|
|
pub type PacketMetadata = crate::storage::PacketMetadata<IpAddress>;
|
|
|
|