File: struct-path-self.stderr

package info (click to toggle)
rustc-web 1.78.0%2Bdfsg1-2~deb12u3
  • links: PTS, VCS
  • area: main
  • in suites: bookworm
  • size: 1,245,420 kB
  • sloc: xml: 147,985; javascript: 18,022; sh: 11,083; python: 10,265; ansic: 6,172; cpp: 5,023; asm: 4,390; makefile: 4,269
file content (80 lines) | stat: -rw-r--r-- 2,429 bytes parent folder | download | duplicates (12)
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
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
error[E0071]: expected struct, variant or union type, found type parameter `Self`
  --> $DIR/struct-path-self.rs:5:17
   |
LL |         let s = Self {};
   |                 ^^^^ not a struct

error[E0109]: type arguments are not allowed on self type
  --> $DIR/struct-path-self.rs:7:24
   |
LL |         let z = Self::<u8> {};
   |                 ----   ^^ type argument not allowed
   |                 |
   |                 not allowed on self type
   |
help: the `Self` type doesn't accept type parameters
   |
LL -         let z = Self::<u8> {};
LL +         let z = Self {};
   |

error[E0071]: expected struct, variant or union type, found type parameter `Self`
  --> $DIR/struct-path-self.rs:7:17
   |
LL |         let z = Self::<u8> {};
   |                 ^^^^^^^^^^ not a struct

error[E0071]: expected struct, variant or union type, found type parameter `Self`
  --> $DIR/struct-path-self.rs:11:13
   |
LL |             Self { .. } => {}
   |             ^^^^ not a struct

error[E0109]: type arguments are not allowed on self type
  --> $DIR/struct-path-self.rs:20:24
   |
LL |         let z = Self::<u8> {};
   |                 ----   ^^ type argument not allowed
   |                 |
   |                 not allowed on self type
   |
note: `Self` is of type `S`
  --> $DIR/struct-path-self.rs:1:8
   |
LL | struct S;
   |        ^ `Self` corresponds to this type, which doesn't have generic parameters
...
LL | impl Tr for S {
   | ------------- `Self` is on type `S` in this `impl`
help: the `Self` type doesn't accept type parameters
   |
LL -         let z = Self::<u8> {};
LL +         let z = Self {};
   |

error[E0109]: type arguments are not allowed on self type
  --> $DIR/struct-path-self.rs:30:24
   |
LL |         let z = Self::<u8> {};
   |                 ----   ^^ type argument not allowed
   |                 |
   |                 not allowed on self type
   |
note: `Self` is of type `S`
  --> $DIR/struct-path-self.rs:1:8
   |
LL | struct S;
   |        ^ `Self` corresponds to this type, which doesn't have generic parameters
...
LL | impl S {
   | ------ `Self` is on type `S` in this `impl`
help: the `Self` type doesn't accept type parameters
   |
LL -         let z = Self::<u8> {};
LL +         let z = Self {};
   |

error: aborting due to 6 previous errors

Some errors have detailed explanations: E0071, E0109.
For more information about an error, try `rustc --explain E0071`.