pipecircuit 0.0.21

Correct. Robust. Fast. Portable. Pick four.
Documentation
use core::num::{NonZeroU32, NonZeroU64};
use pipecircuit::{StateMachine, storage::warp_table::{Capacity,
    observed::AppliedViewChanges, persistent::*}};
fn main() -> Result<(), ()> {
let capacity = Capacity::new(NonZeroU32::MIN);
let mut view = SubscribedView::<u32, u32>::new(ContinuousView::new(capacity));
let mut buffer = AppliedViewChanges::try_new(capacity).map_err(|_| ())?;
let id = RequestId(NonZeroU64::MIN);
let start: SubscriptionStart<(), (), ()> = view
    .subscribe(id, (), Guarantee::Accepted).map_err(|_| ())?;
let reply: ContinuousReply<(), (), (), u32, u32> =
    ContinuousReply::SubscriptionRefused { id, reason: SubscriptionRefusal::Full };
let first = view.step(ReceiveSubscription { session: start.session, reply: &reply }
    .with_changes(&mut buffer));
let second = view.step(ReceiveSubscription { session: start.session, reply: &reply }
    .with_changes(&mut buffer));
drop((first, second));
Ok(())
}