def both.live
import mylsm-lsm-store@0.6.0.1/src/scan/ScanMerge.bend as ScanMergeimport Base
22# Applies ordering and tombstone precedence when both sources have a head.
23def both.live(live: Bool, order: Cmp) -> Decision:
24 match live:
25 case True{}:
26 match order:
27 case LT{}: EmitDelta{}
28 case EQ{}: EmitBoth{}
29 case GT{}: EmitBase{}
30 case False{}:
31 match order:
32 case LT{}: SkipDelta{}
33 case EQ{}: SkipBoth{}
34 case GT{}: EmitBase{}