mirror of
https://github.com/lightningdevkit/rust-lightning.git
synced 2025-01-19 14:44:01 +01:00
Merge pull request #1788 from TheBlueMatt/2022-10-mtlc-writer
Add `WriteableScore` bindings impl for `MultiThreadedLockableScore`
This commit is contained in:
commit
fbacbc08b2
@ -225,6 +225,16 @@ impl<'a, T: Score + 'a> LockableScore<'a> for MultiThreadedLockableScore<T> {
|
||||
}
|
||||
}
|
||||
|
||||
#[cfg(c_bindings)]
|
||||
impl<T: Score> Writeable for MultiThreadedLockableScore<T> {
|
||||
fn write<W: Writer>(&self, writer: &mut W) -> Result<(), io::Error> {
|
||||
self.lock().write(writer)
|
||||
}
|
||||
}
|
||||
|
||||
#[cfg(c_bindings)]
|
||||
impl<'a, T: Score + 'a> WriteableScore<'a> for MultiThreadedLockableScore<T> {}
|
||||
|
||||
#[cfg(c_bindings)]
|
||||
impl<T: Score> MultiThreadedLockableScore<T> {
|
||||
/// Creates a new [`MultiThreadedLockableScore`] given an underlying [`Score`].
|
||||
|
Loading…
Reference in New Issue
Block a user