Progress on syncblock macro

This commit is contained in:
2026-03-19 21:53:07 +01:00
parent 2baee8d28b
commit 6e2283755a
5 changed files with 527 additions and 58 deletions

View File

@ -1,7 +1,6 @@
use crate::{
edge::BlockIOIndex,
io::{AnonymousStreamConsumer, AnonymousStreamProducer},
};
use crate::edge::BlockIOIndex;
use crate::io::AnonymousStreamConsumer;
use crate::io::AnonymousStreamProducer;
pub enum BlockResult
{
@ -51,14 +50,14 @@ pub trait Block
// Represents the input, output, state types
// that a SyncBlock will have to interacti with
pub trait SyncBlockIO
pub trait SyncBlockIO<'view>
{
type StateView;
type Input;
type Output;
}
pub trait SyncBlock: SyncBlockIO
pub trait SyncBlock<'view>: SyncBlockIO<'view>
{
fn sync_work(state: Self::StateView, input: Self::Input) -> Option<Self::Output>;
}