X-Git-Url: http://git.bitcoin.ninja/index.cgi?a=blobdiff_plain;f=lightning%2Fsrc%2Futil%2Fser.rs;h=3de03ea5a0d5efd93b4c3a22e4d88845656dbf23;hb=c06ab02900d454d48f75a54c8ab5c80785acbf8e;hp=6ef29073837aa77d856afa37f65c737e6638abe6;hpb=2fda791d5c36863ca69b290c9293db2fe0d35a25;p=rust-lightning diff --git a/lightning/src/util/ser.rs b/lightning/src/util/ser.rs index 6ef29073..3de03ea5 100644 --- a/lightning/src/util/ser.rs +++ b/lightning/src/util/ser.rs @@ -399,7 +399,7 @@ impl Readable for BigSize { /// In TLV we occasionally send fields which only consist of, or potentially end with, a /// variable-length integer which is simply truncated by skipping high zero bytes. This type /// encapsulates such integers implementing Readable/Writeable for them. -#[cfg_attr(test, derive(PartialEq, Debug))] +#[cfg_attr(test, derive(PartialEq, Eq, Debug))] pub(crate) struct HighZeroBytesDroppedBigSize(pub T); macro_rules! impl_writeable_primitive { @@ -979,7 +979,7 @@ impl Readable for String { /// The character set consists of ASCII alphanumeric characters, hyphens, and periods. /// Its length is guaranteed to be representable by a single byte. /// This serialization is used by BOLT 7 hostnames. -#[derive(Clone, Debug, PartialEq)] +#[derive(Clone, Debug, PartialEq, Eq)] pub struct Hostname(String); impl Hostname { /// Returns the length of the hostname.