backport to 0.15: remove reliance on a trait solver bug (#19360)
A backport of https://github.com/bevyengine/bevy/pull/18840 to version 0.15.3. I was unsure whether I should also update the versions of all crates. Looking at previous backports this was not done. The code which relies on the old solver behavior was introduced in https://github.com/bevyengine/bevy/pull/15184 which is from version 0.15. So this is the only version which needs a backport. cc @mockersf
This commit is contained in:
parent
75f04a743b
commit
aaa01c0787
@ -269,6 +269,7 @@ macro_rules! impl_exclusive_system_function {
|
|||||||
// is a function, potentially because of the multiple impls of `FnMut`
|
// is a function, potentially because of the multiple impls of `FnMut`
|
||||||
#[allow(clippy::too_many_arguments)]
|
#[allow(clippy::too_many_arguments)]
|
||||||
fn call_inner<In: SystemInput, Out, $($param,)*>(
|
fn call_inner<In: SystemInput, Out, $($param,)*>(
|
||||||
|
_: PhantomData<In>,
|
||||||
mut f: impl FnMut(In::Param<'_>, &mut World, $($param,)*) -> Out,
|
mut f: impl FnMut(In::Param<'_>, &mut World, $($param,)*) -> Out,
|
||||||
input: In::Inner<'_>,
|
input: In::Inner<'_>,
|
||||||
world: &mut World,
|
world: &mut World,
|
||||||
@ -277,7 +278,7 @@ macro_rules! impl_exclusive_system_function {
|
|||||||
f(In::wrap(input), world, $($param,)*)
|
f(In::wrap(input), world, $($param,)*)
|
||||||
}
|
}
|
||||||
let ($($param,)*) = param_value;
|
let ($($param,)*) = param_value;
|
||||||
call_inner(self, input, world, $($param),*)
|
call_inner(PhantomData::<In>, self, input, world, $($param),*)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
@ -1023,6 +1023,7 @@ macro_rules! impl_system_function {
|
|||||||
fn run(&mut self, input: In::Inner<'_>, param_value: SystemParamItem< ($($param,)*)>) -> Out {
|
fn run(&mut self, input: In::Inner<'_>, param_value: SystemParamItem< ($($param,)*)>) -> Out {
|
||||||
#[allow(clippy::too_many_arguments)]
|
#[allow(clippy::too_many_arguments)]
|
||||||
fn call_inner<In: SystemInput, Out, $($param,)*>(
|
fn call_inner<In: SystemInput, Out, $($param,)*>(
|
||||||
|
_: PhantomData<In>,
|
||||||
mut f: impl FnMut(In::Param<'_>, $($param,)*)->Out,
|
mut f: impl FnMut(In::Param<'_>, $($param,)*)->Out,
|
||||||
input: In::Inner<'_>,
|
input: In::Inner<'_>,
|
||||||
$($param: $param,)*
|
$($param: $param,)*
|
||||||
@ -1030,7 +1031,7 @@ macro_rules! impl_system_function {
|
|||||||
f(In::wrap(input), $($param,)*)
|
f(In::wrap(input), $($param,)*)
|
||||||
}
|
}
|
||||||
let ($($param,)*) = param_value;
|
let ($($param,)*) = param_value;
|
||||||
call_inner(self, input, $($param),*)
|
call_inner(PhantomData::<In>, self, input, $($param),*)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
Loading…
Reference in New Issue
Block a user