projects
/
ldk-c-bindings
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Merge pull request #38 from TheBlueMatt/main
[ldk-c-bindings]
/
lightning-c-bindings
/
src
/
c_types
/
mod.rs
diff --git
a/lightning-c-bindings/src/c_types/mod.rs
b/lightning-c-bindings/src/c_types/mod.rs
index 83dae2b0c268a8f00553ee95092c1f967059931c..2648a9b39092dbdf96576e4dc998cae10eaf8282 100644
(file)
--- a/
lightning-c-bindings/src/c_types/mod.rs
+++ b/
lightning-c-bindings/src/c_types/mod.rs
@@
-315,6
+315,12
@@
impl TxOut {
}
}
}
}
}
}
+
+#[no_mangle]
+/// Convenience function for constructing a new TxOut
+pub extern "C" fn TxOut_new(script_pubkey: derived::CVec_u8Z, value: u64) -> TxOut {
+ TxOut { script_pubkey, value }
+}
#[no_mangle]
/// Frees the data pointed to by script_pubkey.
pub extern "C" fn TxOut_free(_res: TxOut) { }
#[no_mangle]
/// Frees the data pointed to by script_pubkey.
pub extern "C" fn TxOut_free(_res: TxOut) { }