rust/tests/ui/consts/issue-17718-references.stderr

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

28 lines
897 B
Plaintext
Raw Normal View History

2020-01-10 07:31:36 -06:00
error[E0013]: constants cannot refer to statics
2019-11-19 17:16:58 -06:00
--> $DIR/issue-17718-references.rs:9:29
2018-07-15 16:11:54 -05:00
|
2019-03-09 06:03:44 -06:00
LL | const T2: &'static usize = &S;
2019-11-19 17:16:58 -06:00
| ^
2020-01-10 07:31:36 -06:00
|
= help: consider extracting the value of the `static` to a `const`, and referring to that
2018-07-15 16:11:54 -05:00
2020-01-10 07:31:36 -06:00
error[E0013]: constants cannot refer to statics
2018-12-25 09:56:47 -06:00
--> $DIR/issue-17718-references.rs:14:19
2018-07-15 16:11:54 -05:00
|
2019-03-09 06:03:44 -06:00
LL | const T6: usize = S;
2018-07-15 16:11:54 -05:00
| ^
2020-01-10 07:31:36 -06:00
|
= help: consider extracting the value of the `static` to a `const`, and referring to that
2018-07-15 16:11:54 -05:00
2020-01-10 07:31:36 -06:00
error[E0013]: constants cannot refer to statics
2018-12-25 09:56:47 -06:00
--> $DIR/issue-17718-references.rs:19:33
2018-07-15 16:11:54 -05:00
|
LL | const T10: Struct = Struct { a: S };
| ^
2020-01-10 07:31:36 -06:00
|
= help: consider extracting the value of the `static` to a `const`, and referring to that
2018-07-15 16:11:54 -05:00
error: aborting due to 3 previous errors
For more information about this error, try `rustc --explain E0013`.