about summary refs log tree commit diff
path: root/tests/ui/traits/non_lifetime_binders/shadowed.stderr
blob: 59a073aefc9612b136afa7ea207719df65e5258d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
error[E0403]: the name `T` is already used for a generic parameter in this item's generic parameters
  --> $DIR/shadowed.rs:4:28
   |
LL | fn function<T>() where for<T> (): Sized {}
   |             -              ^ already used
   |             |
   |             first use of `T`

error[E0403]: the name `T` is already used for a generic parameter in this item's generic parameters
  --> $DIR/shadowed.rs:7:31
   |
LL | struct Struct<T>(T) where for<T> (): Sized;
   |               -               ^ already used
   |               |
   |               first use of `T`

error[E0403]: the name `T` is already used for a generic parameter in this item's generic parameters
  --> $DIR/shadowed.rs:11:27
   |
LL | impl<T> Struct<T> {
   |      - first use of `T`
LL |     fn method() where for<T> (): Sized {}
   |                           ^ already used

error[E0403]: the name `T` is already used for a generic parameter in this item's generic parameters
  --> $DIR/shadowed.rs:15:28
   |
LL | fn repeated() where for<T, T> (): Sized {}
   |                         -  ^ already used
   |                         |
   |                         first use of `T`

warning: the feature `non_lifetime_binders` is incomplete and may not be safe to use and/or cause compiler crashes
  --> $DIR/shadowed.rs:1:12
   |
LL | #![feature(non_lifetime_binders)]
   |            ^^^^^^^^^^^^^^^^^^^^
   |
   = note: see issue #108185 <https://github.com/rust-lang/rust/issues/108185> for more information
   = note: `#[warn(incomplete_features)]` on by default

error: aborting due to 4 previous errors; 1 warning emitted

For more information about this error, try `rustc --explain E0403`.