Skip to main content

transform_mut_yokeable

Function transform_mut_yokeable 

Source
pub(crate) fn transform_mut_yokeable<'a, Y, F, R>(
    yokeable: &'a mut Y,
    f: F,
) -> R
where Y: Yokeable<'a>, F: 'static + for<'b> FnOnce(&'b mut Y::Output) -> R, R: 'static,
Expand description

This method casts yokeable between &'a mut Y<'static> and &'a mut Y<'a>, and passes it to f.

See Yokeable::transform_mut for why this is safe, noting that no 'static return type can leak data from the cart or Yokeable.