]> git.lizzy.rs Git - rust.git/blob - src/test/ui/const-generics/const-arg-in-const-arg.min.stderr
Rollup merge of #78985 - lcnr:cg-drop-test, r=nikomatsakis
[rust.git] / src / test / ui / const-generics / const-arg-in-const-arg.min.stderr
1 error: generic parameters may not be used in const operations
2   --> $DIR/const-arg-in-const-arg.rs:14:23
3    |
4 LL |     let _: [u8; foo::<T>()];
5    |                       ^ cannot perform const operation using `T`
6    |
7    = note: type parameters may not be used in const expressions
8
9 error: generic parameters may not be used in const operations
10   --> $DIR/const-arg-in-const-arg.rs:15:23
11    |
12 LL |     let _: [u8; bar::<N>()];
13    |                       ^ cannot perform const operation using `N`
14    |
15    = help: const parameters may only be used as standalone arguments, i.e. `N`
16
17 error: generic parameters may not be used in const operations
18   --> $DIR/const-arg-in-const-arg.rs:25:23
19    |
20 LL |     let _ = [0; bar::<N>()];
21    |                       ^ cannot perform const operation using `N`
22    |
23    = help: const parameters may only be used as standalone arguments, i.e. `N`
24
25 error: generic parameters may not be used in const operations
26   --> $DIR/const-arg-in-const-arg.rs:30:24
27    |
28 LL |     let _: Foo<{ foo::<T>() }>;
29    |                        ^ cannot perform const operation using `T`
30    |
31    = note: type parameters may not be used in const expressions
32
33 error: generic parameters may not be used in const operations
34   --> $DIR/const-arg-in-const-arg.rs:31:24
35    |
36 LL |     let _: Foo<{ bar::<N>() }>;
37    |                        ^ cannot perform const operation using `N`
38    |
39    = help: const parameters may only be used as standalone arguments, i.e. `N`
40
41 error: generic parameters may not be used in const operations
42   --> $DIR/const-arg-in-const-arg.rs:36:27
43    |
44 LL |     let _ = Foo::<{ foo::<T>() }>;
45    |                           ^ cannot perform const operation using `T`
46    |
47    = note: type parameters may not be used in const expressions
48
49 error: generic parameters may not be used in const operations
50   --> $DIR/const-arg-in-const-arg.rs:37:27
51    |
52 LL |     let _ = Foo::<{ bar::<N>() }>;
53    |                           ^ cannot perform const operation using `N`
54    |
55    = help: const parameters may only be used as standalone arguments, i.e. `N`
56
57 error[E0658]: a non-static lifetime is not allowed in a `const`
58   --> $DIR/const-arg-in-const-arg.rs:16:23
59    |
60 LL |     let _: [u8; faz::<'a>(&())];
61    |                       ^^
62    |
63    = note: see issue #44580 <https://github.com/rust-lang/rust/issues/44580> for more information
64    = help: add `#![feature(const_generics)]` to the crate attributes to enable
65
66 error[E0658]: a non-static lifetime is not allowed in a `const`
67   --> $DIR/const-arg-in-const-arg.rs:17:23
68    |
69 LL |     let _: [u8; baz::<'a>(&())];
70    |                       ^^
71    |
72    = note: see issue #44580 <https://github.com/rust-lang/rust/issues/44580> for more information
73    = help: add `#![feature(const_generics)]` to the crate attributes to enable
74
75 error[E0658]: a non-static lifetime is not allowed in a `const`
76   --> $DIR/const-arg-in-const-arg.rs:18:23
77    |
78 LL |     let _: [u8; faz::<'b>(&())];
79    |                       ^^
80    |
81    = note: see issue #44580 <https://github.com/rust-lang/rust/issues/44580> for more information
82    = help: add `#![feature(const_generics)]` to the crate attributes to enable
83
84 error[E0658]: a non-static lifetime is not allowed in a `const`
85   --> $DIR/const-arg-in-const-arg.rs:19:23
86    |
87 LL |     let _: [u8; baz::<'b>(&())];
88    |                       ^^
89    |
90    = note: see issue #44580 <https://github.com/rust-lang/rust/issues/44580> for more information
91    = help: add `#![feature(const_generics)]` to the crate attributes to enable
92
93 error[E0658]: a non-static lifetime is not allowed in a `const`
94   --> $DIR/const-arg-in-const-arg.rs:26:23
95    |
96 LL |     let _ = [0; faz::<'a>(&())];
97    |                       ^^
98    |
99    = note: see issue #44580 <https://github.com/rust-lang/rust/issues/44580> for more information
100    = help: add `#![feature(const_generics)]` to the crate attributes to enable
101
102 error[E0658]: a non-static lifetime is not allowed in a `const`
103   --> $DIR/const-arg-in-const-arg.rs:27:23
104    |
105 LL |     let _ = [0; baz::<'a>(&())];
106    |                       ^^
107    |
108    = note: see issue #44580 <https://github.com/rust-lang/rust/issues/44580> for more information
109    = help: add `#![feature(const_generics)]` to the crate attributes to enable
110
111 error[E0658]: a non-static lifetime is not allowed in a `const`
112   --> $DIR/const-arg-in-const-arg.rs:28:23
113    |
114 LL |     let _ = [0; faz::<'b>(&())];
115    |                       ^^
116    |
117    = note: see issue #44580 <https://github.com/rust-lang/rust/issues/44580> for more information
118    = help: add `#![feature(const_generics)]` to the crate attributes to enable
119
120 error[E0658]: a non-static lifetime is not allowed in a `const`
121   --> $DIR/const-arg-in-const-arg.rs:29:23
122    |
123 LL |     let _ = [0; baz::<'b>(&())];
124    |                       ^^
125    |
126    = note: see issue #44580 <https://github.com/rust-lang/rust/issues/44580> for more information
127    = help: add `#![feature(const_generics)]` to the crate attributes to enable
128
129 error[E0658]: a non-static lifetime is not allowed in a `const`
130   --> $DIR/const-arg-in-const-arg.rs:32:24
131    |
132 LL |     let _: Foo<{ faz::<'a>(&()) }>;
133    |                        ^^
134    |
135    = note: see issue #44580 <https://github.com/rust-lang/rust/issues/44580> for more information
136    = help: add `#![feature(const_generics)]` to the crate attributes to enable
137
138 error[E0658]: a non-static lifetime is not allowed in a `const`
139   --> $DIR/const-arg-in-const-arg.rs:33:24
140    |
141 LL |     let _: Foo<{ baz::<'a>(&()) }>;
142    |                        ^^
143    |
144    = note: see issue #44580 <https://github.com/rust-lang/rust/issues/44580> for more information
145    = help: add `#![feature(const_generics)]` to the crate attributes to enable
146
147 error[E0658]: a non-static lifetime is not allowed in a `const`
148   --> $DIR/const-arg-in-const-arg.rs:34:24
149    |
150 LL |     let _: Foo<{ faz::<'b>(&()) }>;
151    |                        ^^
152    |
153    = note: see issue #44580 <https://github.com/rust-lang/rust/issues/44580> for more information
154    = help: add `#![feature(const_generics)]` to the crate attributes to enable
155
156 error[E0658]: a non-static lifetime is not allowed in a `const`
157   --> $DIR/const-arg-in-const-arg.rs:35:24
158    |
159 LL |     let _: Foo<{ baz::<'b>(&()) }>;
160    |                        ^^
161    |
162    = note: see issue #44580 <https://github.com/rust-lang/rust/issues/44580> for more information
163    = help: add `#![feature(const_generics)]` to the crate attributes to enable
164
165 error[E0658]: a non-static lifetime is not allowed in a `const`
166   --> $DIR/const-arg-in-const-arg.rs:38:27
167    |
168 LL |     let _ = Foo::<{ faz::<'a>(&()) }>;
169    |                           ^^
170    |
171    = note: see issue #44580 <https://github.com/rust-lang/rust/issues/44580> for more information
172    = help: add `#![feature(const_generics)]` to the crate attributes to enable
173
174 error[E0658]: a non-static lifetime is not allowed in a `const`
175   --> $DIR/const-arg-in-const-arg.rs:39:27
176    |
177 LL |     let _ = Foo::<{ baz::<'a>(&()) }>;
178    |                           ^^
179    |
180    = note: see issue #44580 <https://github.com/rust-lang/rust/issues/44580> for more information
181    = help: add `#![feature(const_generics)]` to the crate attributes to enable
182
183 error[E0658]: a non-static lifetime is not allowed in a `const`
184   --> $DIR/const-arg-in-const-arg.rs:40:27
185    |
186 LL |     let _ = Foo::<{ faz::<'b>(&()) }>;
187    |                           ^^
188    |
189    = note: see issue #44580 <https://github.com/rust-lang/rust/issues/44580> for more information
190    = help: add `#![feature(const_generics)]` to the crate attributes to enable
191
192 error[E0658]: a non-static lifetime is not allowed in a `const`
193   --> $DIR/const-arg-in-const-arg.rs:41:27
194    |
195 LL |     let _ = Foo::<{ baz::<'b>(&()) }>;
196    |                           ^^
197    |
198    = note: see issue #44580 <https://github.com/rust-lang/rust/issues/44580> for more information
199    = help: add `#![feature(const_generics)]` to the crate attributes to enable
200
201 error: aborting due to 23 previous errors
202
203 For more information about this error, try `rustc --explain E0658`.