]> git.bitcoin.ninja Git - ldk-c-bindings/commitdiff
Correct manual conversion for `ChainHash`
authorMatt Corallo <git@bluematt.me>
Mon, 23 Oct 2023 23:36:44 +0000 (23:36 +0000)
committerMatt Corallo <git@bluematt.me>
Mon, 23 Oct 2023 23:36:44 +0000 (23:36 +0000)
c-bindings-gen/src/types.rs

index 1cb7420e7d8c8686c73fed2038fc6fb69113459b..3ac40cfa5600067c8a471d0add66562b1e1ce7f7 100644 (file)
@@ -1534,7 +1534,7 @@ impl<'a, 'c: 'a> TypeResolver<'a, 'c> {
                                if is_ref => Some(".as_inner()"),
                        "bitcoin::hash_types::Txid"|"bitcoin::BlockHash"|"bitcoin::hash_types::BlockHash"|"bitcoin_hashes::sha256::Hash"
                                if !is_ref => Some(".into_inner() }"),
-                       "bitcoin::blockdata::constants::ChainHash" if is_ref => Some(".as_bytes() }"),
+                       "bitcoin::blockdata::constants::ChainHash" if is_ref => Some(".as_bytes()"),
                        "bitcoin::blockdata::constants::ChainHash" if !is_ref => Some(".to_bytes() }"),
                        "bitcoin::secp256k1::Message" if !is_ref => Some(".as_ref().clone() }"),
                        "lightning::ln::PaymentHash"|"lightning::ln::PaymentPreimage"|"lightning::ln::PaymentSecret"