]> git.lizzy.rs Git - rust.git/blob - src/test/ui/issues/issue-43105.stderr
Report const eval error inside the query
[rust.git] / src / test / ui / issues / issue-43105.stderr
1 error[E0015]: calls in constants are limited to constant functions, tuple structs and tuple variants
2   --> $DIR/issue-43105.rs:13:17
3    |
4 LL | const NUM: u8 = xyz();
5    |                 ^^^^^
6
7 error: any use of this value will cause an error
8   --> $DIR/issue-43105.rs:13:1
9    |
10 LL | const NUM: u8 = xyz();
11    | ^^^^^^^^^^^^^^^^-----^
12    |                 |
13    |                 calling non-const fn `xyz`
14    |
15    = note: #[deny(const_err)] on by default
16
17 error: could not evaluate constant pattern
18   --> $DIR/issue-43105.rs:19:9
19    |
20 LL |         NUM => unimplemented!(), //~ ERROR could not evaluate constant pattern
21    |         ^^^
22
23 error: aborting due to 3 previous errors
24
25 For more information about this error, try `rustc --explain E0015`.