2021-12-09 11:10:05 -06:00
|
|
|
error[E0015]: cannot call non-const fn `f` in constants
|
2018-12-25 09:56:47 -06:00
|
|
|
--> $DIR/const-call.rs:6:17
|
2018-08-08 07:28:26 -05:00
|
|
|
|
|
|
|
|
LL | let _ = [0; f(2)];
|
|
|
|
| ^^^^
|
2021-12-09 11:10:05 -06:00
|
|
|
|
|
|
|
|
= note: calls in constants are limited to constant functions, tuple structs and tuple variants
|
2018-08-08 07:28:26 -05:00
|
|
|
|
2020-11-06 09:57:05 -06:00
|
|
|
error: aborting due to previous error
|
2018-08-08 07:28:26 -05:00
|
|
|
|
2020-11-06 09:57:05 -06:00
|
|
|
For more information about this error, try `rustc --explain E0015`.
|