Fix build warning about public_from_secret_hex.
authorArik Sosman <git@arik.io>
Sat, 24 Jun 2023 05:33:55 +0000 (22:33 -0700)
committerArik Sosman <git@arik.io>
Sat, 24 Jun 2023 17:52:27 +0000 (10:52 -0700)
lightning/src/ln/channel.rs

index 4d6e02ccf69e4bdfa3e4fc3136991bae3fe1cdba..db38588230b77e153f967aba6781296fe459967d 100644 (file)
@@ -7405,7 +7405,7 @@ mod tests {
                }
        }
 
-       #[cfg(not(feature = "grind_signatures"))]
+       #[cfg(all(feature = "_test_vectors", not(feature = "grind_signatures")))]
        fn public_from_secret_hex(secp_ctx: &Secp256k1<bitcoin::secp256k1::All>, hex: &str) -> PublicKey {
                PublicKey::from_secret_key(&secp_ctx, &SecretKey::from_slice(&hex::decode(hex).unwrap()[..]).unwrap())
        }