Merge pull request #1347 from jkczyz/2022-03-log-approximation
[rust-lightning] / lightning / src / ln / script.rs
index 00ad48bb1e31c07cf695f52282ea2b746cf05455..a9f44bae1aec79199230d467f426b50934c225dd 100644 (file)
@@ -17,11 +17,11 @@ use io;
 /// A script pubkey for shutting down a channel as defined by [BOLT #2].
 ///
 /// [BOLT #2]: https://github.com/lightningnetwork/lightning-rfc/blob/master/02-peer-protocol.md
-#[derive(Clone)]
+#[derive(Clone, PartialEq)]
 pub struct ShutdownScript(ShutdownScriptImpl);
 
 /// An error occurring when converting from [`Script`] to [`ShutdownScript`].
-#[derive(Debug)]
+#[derive(Clone, Debug)]
 pub struct InvalidShutdownScript {
        /// The script that did not meet the requirements from [BOLT #2].
        ///
@@ -29,7 +29,7 @@ pub struct InvalidShutdownScript {
        pub script: Script
 }
 
-#[derive(Clone)]
+#[derive(Clone, PartialEq)]
 enum ShutdownScriptImpl {
        /// [`PublicKey`] used to form a P2WPKH script pubkey. Used to support backward-compatible
        /// serialization.