[bdk_chain_redesign] Documentation improvements
This commit is contained in:
parent
ee1060f2ff
commit
a7fbe0ac67
@ -271,6 +271,8 @@ impl<A: BlockAnchor> FullTxOut<ObservedAs<A>> {
|
|||||||
|
|
||||||
/// Whether the utxo is/was/will be spendable with chain `tip`.
|
/// Whether the utxo is/was/will be spendable with chain `tip`.
|
||||||
///
|
///
|
||||||
|
/// Currently this method does not take into account the locktime.
|
||||||
|
///
|
||||||
/// This is the alternative version of [`is_spendable_at`] which depends on `chain_position`
|
/// This is the alternative version of [`is_spendable_at`] which depends on `chain_position`
|
||||||
/// being a [`ObservedAs<A>`] where `A` implements [`BlockAnchor`].
|
/// being a [`ObservedAs<A>`] where `A` implements [`BlockAnchor`].
|
||||||
///
|
///
|
||||||
@ -286,7 +288,6 @@ impl<A: BlockAnchor> FullTxOut<ObservedAs<A>> {
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
// [TODO] Why are unconfirmed txs always considered unspendable here?
|
|
||||||
ObservedAs::Unconfirmed(_) => return false,
|
ObservedAs::Unconfirmed(_) => return false,
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -55,10 +55,11 @@ impl<A: BlockAnchor, IA: Append> Append for IndexedAdditions<A, IA> {
|
|||||||
self.graph_additions.append(other.graph_additions);
|
self.graph_additions.append(other.graph_additions);
|
||||||
self.index_additions.append(other.index_additions);
|
self.index_additions.append(other.index_additions);
|
||||||
if self.last_height < other.last_height {
|
if self.last_height < other.last_height {
|
||||||
let last_height = other
|
self.last_height = Some(
|
||||||
.last_height
|
other
|
||||||
.expect("must exist as it is larger than self.last_height");
|
.last_height
|
||||||
self.last_height.replace(last_height);
|
.expect("must exist as it is larger than self.last_height"),
|
||||||
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user