Add monotonic check interface

This commit is contained in:
Dominik Werder
2025-03-21 14:43:35 +01:00
parent 7977c3c6b7
commit 5132db09f9

View File

@@ -50,6 +50,7 @@ pub trait MergeableTy: fmt::Debug + WithLen + ByteEstimate + Unpin + Sized {
fn tss_for_testing(&self) -> VecDeque<TsNano>;
fn drain_into(&mut self, dst: &mut Self, range: Range<usize>) -> DrainIntoDstResult;
fn drain_into_new(&mut self, range: Range<usize>) -> DrainIntoNewResult<Self>;
fn is_strict_monotonic(&self) -> bool;
fn is_consistent(&self) -> bool;
}
@@ -63,5 +64,6 @@ pub trait MergeableDyn: fmt::Debug + WithLen + ByteEstimate + Unpin + AsAnyMut {
fn drain_into(&mut self, dst: &mut dyn MergeableDyn, range: Range<usize>)
-> DrainIntoDstResult;
fn drain_into_new(&mut self, range: Range<usize>) -> DrainIntoNewDynResult;
fn is_strict_monotonic(&self) -> bool;
fn is_consistent(&self) -> bool;
}