]> git.lizzy.rs Git - rust.git/blob - tests/ui/specialization/default-generic-associated-type-bound.stderr
Rollup merge of #106638 - RalfJung:realstd, r=thomcc
[rust.git] / tests / ui / specialization / default-generic-associated-type-bound.stderr
1 warning: the feature `specialization` is incomplete and may not be safe to use and/or cause compiler crashes
2   --> $DIR/default-generic-associated-type-bound.rs:3:12
3    |
4 LL | #![feature(specialization)]
5    |            ^^^^^^^^^^^^^^
6    |
7    = note: see issue #31844 <https://github.com/rust-lang/rust/issues/31844> for more information
8    = help: consider using `min_specialization` instead, which is more stable and complete
9    = note: `#[warn(incomplete_features)]` on by default
10
11 error[E0277]: can't compare `T` with `T`
12   --> $DIR/default-generic-associated-type-bound.rs:17:26
13    |
14 LL |     default type U<'a> = &'a T;
15    |                          ^^^^^ no implementation for `T == T`
16    |
17    = note: required for `&'a T` to implement `PartialEq`
18 note: required by a bound in `X::U`
19   --> $DIR/default-generic-associated-type-bound.rs:7:17
20    |
21 LL |     type U<'a>: PartialEq<&'a Self> where Self: 'a;
22    |                 ^^^^^^^^^^^^^^^^^^^ required by this bound in `X::U`
23 help: consider further restricting this bound
24    |
25 LL | impl<T: 'static + std::cmp::PartialEq> X for T {
26    |                 +++++++++++++++++++++
27
28 error: aborting due to previous error; 1 warning emitted
29
30 For more information about this error, try `rustc --explain E0277`.