Skip to main content

check_trait_method_formals

Function check_trait_method_formals 

Source
fn check_trait_method_formals(
    methods: &[TraitMethod],
    class_system: ClassSystem,
) -> Result<()>
Expand description

Check the R formals of every trait method (check_r_formals). Every dispatching class system defaults an instance method’s receiver to x. S3/S4 existing-generic overrides can select another receiver. S7 shortcuts and Env/R6 trait methods use the injected receiver .mx_self, which cannot be spelled by a Rust parameter.