Fix SimpleRestartingEventManager broken generics

This commit is contained in:
Andrea Fioraldi 2021-07-22 11:58:24 +02:00
parent 8e745f7d90
commit 7e06b90364

View File

@ -214,7 +214,7 @@ where
/// `restarter` will start a new process each time the child crashes or times out. /// `restarter` will start a new process each time the child crashes or times out.
#[cfg(feature = "std")] #[cfg(feature = "std")]
#[allow(clippy::default_trait_access)] #[allow(clippy::default_trait_access)]
pub struct SimpleRestartingEventManager<'a, C, I, S, SP, ST> pub struct SimpleRestartingEventManager<'a, C, I, S, SC, SP, ST>
where where
C: Corpus<I>, C: Corpus<I>,
I: Input, I: Input,
@ -227,11 +227,12 @@ where
/// [`StateRestorer`] for restarts /// [`StateRestorer`] for restarts
staterestorer: StateRestorer<SP>, staterestorer: StateRestorer<SP>,
/// Phantom data /// Phantom data
_phantom: PhantomData<&'a (C, I, S)>, _phantom: PhantomData<&'a (C, I, S, SC)>,
} }
#[cfg(feature = "std")] #[cfg(feature = "std")]
impl<'a, C, I, S, SP, ST> EventFirer<I, S> for SimpleRestartingEventManager<'a, C, I, S, SP, ST> impl<'a, C, I, S, SC, SP, ST> EventFirer<I, S>
for SimpleRestartingEventManager<'a, C, I, S, SC, SP, ST>
where where
C: Corpus<I>, C: Corpus<I>,
I: Input, I: Input,
@ -245,7 +246,8 @@ where
} }
#[cfg(feature = "std")] #[cfg(feature = "std")]
impl<'a, C, I, S, SP, ST> EventRestarter<S> for SimpleRestartingEventManager<'a, C, I, S, SP, ST> impl<'a, C, I, S, SC, SP, ST> EventRestarter<S>
for SimpleRestartingEventManager<'a, C, I, S, SC, SP, ST>
where where
C: Corpus<I>, C: Corpus<I>,
I: Input, I: Input,
@ -262,8 +264,8 @@ where
} }
#[cfg(feature = "std")] #[cfg(feature = "std")]
impl<'a, C, E, I, S, SP, ST, Z> EventProcessor<E, I, S, Z> impl<'a, C, E, I, S, SC, SP, ST, Z> EventProcessor<E, I, S, Z>
for SimpleRestartingEventManager<'a, C, I, S, SP, ST> for SimpleRestartingEventManager<'a, C, I, S, SC, SP, ST>
where where
C: Corpus<I>, C: Corpus<I>,
I: Input, I: Input,
@ -277,8 +279,8 @@ where
} }
#[cfg(feature = "std")] #[cfg(feature = "std")]
impl<'a, C, E, I, S, SP, ST, Z> EventManager<E, I, S, Z> impl<'a, C, E, I, S, SC, SP, ST, Z> EventManager<E, I, S, Z>
for SimpleRestartingEventManager<'a, C, I, S, SP, ST> for SimpleRestartingEventManager<'a, C, I, S, SC, SP, ST>
where where
C: Corpus<I>, C: Corpus<I>,
I: Input, I: Input,
@ -289,7 +291,8 @@ where
} }
#[cfg(feature = "std")] #[cfg(feature = "std")]
impl<'a, C, I, S, SP, ST> HasEventManagerId for SimpleRestartingEventManager<'a, C, I, S, SP, ST> impl<'a, C, I, S, SC, SP, ST> HasEventManagerId
for SimpleRestartingEventManager<'a, C, I, S, SC, SP, ST>
where where
C: Corpus<I>, C: Corpus<I>,
I: Input, I: Input,
@ -304,11 +307,12 @@ where
#[cfg(feature = "std")] #[cfg(feature = "std")]
#[allow(clippy::type_complexity, clippy::too_many_lines)] #[allow(clippy::type_complexity, clippy::too_many_lines)]
impl<'a, C, I, S, SP, ST> SimpleRestartingEventManager<'a, C, I, S, SP, ST> impl<'a, C, I, S, SC, SP, ST> SimpleRestartingEventManager<'a, C, I, S, SC, SP, ST>
where where
C: Corpus<I>, C: Corpus<I>,
I: Input, I: Input,
S: DeserializeOwned + Serialize + HasCorpus<C, I> + HasSolutions<C, I>, S: DeserializeOwned + Serialize + HasCorpus<C, I> + HasSolutions<SC, I>,
SC: Corpus<I>,
SP: ShMemProvider, SP: ShMemProvider,
ST: Stats, //TODO CE: CustomEvent, ST: Stats, //TODO CE: CustomEvent,
{ {