Skip to main content

refuse_rng_guard_in_trait_method

Function refuse_rng_guard_in_trait_method 

Source
pub(crate) fn refuse_rng_guard_in_trait_method(
    inputs: &Punctuated<FnArg, Comma>,
) -> Result<()>
Expand description

Refuse an RngGuard parameter on a trait method (#2002), in any shape: the trait declaration and a trait impl. A trait method’s arguments cross the vtable as values its shim converts with TryFromSexp, and the guard is no R value.