error[E0425]: cannot find value `bar` in this scope --> $DIR/not_wf_param_in_rpitit.rs:3:30 | LL | trait Trait { | ^^^ not found in this scope error[E0391]: cycle detected when computing type of `Trait::N` --> $DIR/not_wf_param_in_rpitit.rs:3:22 | LL | trait Trait { | ^^^^^ | = note: ...which immediately requires computing type of `Trait::N` again note: cycle used when computing explicit predicates of trait `Trait` --> $DIR/not_wf_param_in_rpitit.rs:3:1 | LL | trait Trait { | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ = note: see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information error[E0038]: the trait `Trait` cannot be made into an object --> $DIR/not_wf_param_in_rpitit.rs:3:22 | LL | trait Trait { | ^^^^^ `Trait` cannot be made into an object | note: for a trait to be "dyn-compatible" it needs to allow building a vtable to allow the call to be resolvable dynamically; for more information visit --> $DIR/not_wf_param_in_rpitit.rs:11:14 | LL | trait Trait { | ----- this trait cannot be made into an object... ... LL | async fn a() {} | ^ ...because associated function `a` has no `self` parameter help: consider turning `a` into a method by giving it a `&self` argument | LL | async fn a(&self) {} | +++++ help: alternatively, consider constraining `a` so it does not apply to trait objects | LL | async fn a() where Self: Sized {} | +++++++++++++++++ error[E0038]: the trait `Trait` cannot be made into an object --> $DIR/not_wf_param_in_rpitit.rs:3:13 | LL | trait Trait { | ^^^^^^^^^^^^^^^^^^^^ `Trait` cannot be made into an object | note: for a trait to be "dyn-compatible" it needs to allow building a vtable to allow the call to be resolvable dynamically; for more information visit --> $DIR/not_wf_param_in_rpitit.rs:11:14 | LL | trait Trait { | ----- this trait cannot be made into an object... ... LL | async fn a() {} | ^ ...because associated function `a` has no `self` parameter help: consider turning `a` into a method by giving it a `&self` argument | LL | async fn a(&self) {} | +++++ help: alternatively, consider constraining `a` so it does not apply to trait objects | LL | async fn a() where Self: Sized {} | +++++++++++++++++ error: `(dyn Trait<{const error}> + 'static)` is forbidden as the type of a const generic parameter --> $DIR/not_wf_param_in_rpitit.rs:3:22 | LL | trait Trait { | ^^^^^ | = note: the only supported types are integers, `bool` and `char` error[E0038]: the trait `Trait` cannot be made into an object --> $DIR/not_wf_param_in_rpitit.rs:3:13 | LL | trait Trait { | ^^^^^^^^^^^^^^^^^^^^ `Trait` cannot be made into an object | note: for a trait to be "dyn-compatible" it needs to allow building a vtable to allow the call to be resolvable dynamically; for more information visit --> $DIR/not_wf_param_in_rpitit.rs:11:14 | LL | trait Trait { | ----- this trait cannot be made into an object... ... LL | async fn a() {} | ^ ...because associated function `a` has no `self` parameter = note: duplicate diagnostic emitted due to `-Z deduplicate-diagnostics=no` help: consider turning `a` into a method by giving it a `&self` argument | LL | async fn a(&self) {} | +++++ help: alternatively, consider constraining `a` so it does not apply to trait objects | LL | async fn a() where Self: Sized {} | +++++++++++++++++ error[E0782]: trait objects must include the `dyn` keyword --> $DIR/not_wf_param_in_rpitit.rs:3:22 | LL | trait Trait { | ^^^^^ | help: add `dyn` keyword before this trait | LL | trait Trait { | +++ error: aborting due to 7 previous errors Some errors have detailed explanations: E0038, E0391, E0425, E0782. For more information about an error, try `rustc --explain E0038`.