sark-core 0.28.1

Fiber-free request, route, dispatch, and lifecycle core for Sark
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
use crate::{body::admit, manifold::stream::Boundary};

pub(in crate::body) struct Advance<'a> {
    pub(super) track: &'a mut admit::Track<Boundary>,
    pub(super) next: usize,
}

impl Advance<'_> {
    pub(in crate::body) fn commit(self) {
        self.track.len = self.next;
    }
}

const _: () = assert!(core::mem::size_of::<Advance<'_>>() == 2 * core::mem::size_of::<usize>());