1 warning: default bound relaxed for a type parameter, but this does nothing because the given bound is not a default; only `?Sized` is supported
2 --> $DIR/issue-87199.rs:8:8
4 LL | fn arg<T: ?Send>(_: T) {}
7 warning: default bound relaxed for a type parameter, but this does nothing because the given bound is not a default; only `?Sized` is supported
8 --> $DIR/issue-87199.rs:10:12
10 LL | fn ref_arg<T: ?Send>(_: &T) {}
13 warning: default bound relaxed for a type parameter, but this does nothing because the given bound is not a default; only `?Sized` is supported
14 --> $DIR/issue-87199.rs:12:13
16 LL | fn ret() -> impl Iterator<Item = ()> + ?Send { std::iter::empty() }
17 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
19 error[E0277]: the size for values of type `[i32]` cannot be known at compilation time
20 --> $DIR/issue-87199.rs:18:22
22 LL | ref_arg::<[i32]>(&[5]);
23 | ---------------- ^^^^ doesn't have a size known at compile-time
25 | required by a bound introduced by this call
27 = help: the trait `Sized` is not implemented for `[i32]`
28 note: required by a bound in `ref_arg`
29 --> $DIR/issue-87199.rs:10:12
31 LL | fn ref_arg<T: ?Send>(_: &T) {}
32 | ^ required by this bound in `ref_arg`
33 help: consider relaxing the implicit `Sized` restriction
35 LL | fn ref_arg<T: ?Send + ?Sized>(_: &T) {}
38 error: aborting due to previous error; 3 warnings emitted
40 For more information about this error, try `rustc --explain E0277`.