]> git.proxmox.com Git - rustc.git/blame - src/test/ui/issues/issue-86756.stderr
New upstream version 1.66.0+dfsg1
[rustc.git] / src / test / ui / issues / issue-86756.stderr
CommitLineData
94222f64
XL
1error[E0403]: the name `T` is already used for a generic parameter in this item's generic parameters
2 --> $DIR/issue-86756.rs:1:14
3 |
4LL | trait Foo<T, T = T> {}
5 | - ^ already used
6 | |
7 | first use of `T`
8
9error[E0412]: cannot find type `dyn` in this scope
10 --> $DIR/issue-86756.rs:5:10
11 |
12LL | fn eq<A, B>() {
13 | - help: you might be missing a type parameter: `, dyn`
14LL | eq::<dyn, Foo>
15 | ^^^ not found in this scope
16
17warning: trait objects without an explicit `dyn` are deprecated
18 --> $DIR/issue-86756.rs:5:15
19 |
20LL | eq::<dyn, Foo>
a2a8927a 21 | ^^^
94222f64 22 |
94222f64
XL
23 = warning: this is accepted in the current edition (Rust 2015) but is a hard error in Rust 2021!
24 = note: for more information, see <https://doc.rust-lang.org/nightly/edition-guide/rust-2021/warnings-promoted-to-error.html>
2b03887a 25 = note: `#[warn(bare_trait_objects)]` on by default
a2a8927a
XL
26help: use `dyn`
27 |
f2b60f7d
FG
28LL | eq::<dyn, dyn Foo>
29 | +++
94222f64
XL
30
31error[E0107]: missing generics for trait `Foo`
32 --> $DIR/issue-86756.rs:5:15
33 |
34LL | eq::<dyn, Foo>
35 | ^^^ expected at least 1 generic argument
36 |
37note: trait defined here, with at least 1 generic parameter: `T`
38 --> $DIR/issue-86756.rs:1:7
39 |
40LL | trait Foo<T, T = T> {}
41 | ^^^ -
42help: add missing generic argument
43 |
44LL | eq::<dyn, Foo<T>>
45 | ~~~~~~
46
47error: aborting due to 3 previous errors; 1 warning emitted
48
49Some errors have detailed explanations: E0107, E0403, E0412.
50For more information about an error, try `rustc --explain E0107`.