commerce-theory 0.1.1

Runtime Rust mirror of the CommerceTheory Lean package
Documentation
1
2
3
4
5
6
7
8
9
10
use crate::event_replay::Timed;
use crate::foundation::*;
use crate::inventory::*;

pub fn timed_allocations_total(allocations: &[Allocation]) -> DomainResult<Timed<Quantity>> {
    Ok(Timed::new(
        allocations_total(allocations)?,
        allocations.len() as Nat,
    ))
}