2020-02-11 07:19:21 +00:00
|
|
|
error[E0379]: functions in traits cannot be declared const
|
2021-04-26 12:53:41 +00:00
|
|
|
--> $DIR/const-fn-not-in-trait.rs:5:5
|
2017-12-10 19:47:55 +00:00
|
|
|
|
|
2018-02-23 00:42:32 +00:00
|
|
|
LL | const fn f() -> u32;
|
2024-01-01 23:57:30 +00:00
|
|
|
| ^^^^^-
|
|
|
|
| |
|
|
|
|
| functions in traits cannot be const
|
|
|
|
| help: remove the `const`
|
2017-12-10 19:47:55 +00:00
|
|
|
|
2020-02-11 07:19:21 +00:00
|
|
|
error[E0379]: functions in traits cannot be declared const
|
2021-04-26 12:53:41 +00:00
|
|
|
--> $DIR/const-fn-not-in-trait.rs:7:5
|
2017-12-10 19:47:55 +00:00
|
|
|
|
|
2020-02-11 07:19:21 +00:00
|
|
|
LL | const fn g() -> u32 {
|
2024-01-01 23:57:30 +00:00
|
|
|
| ^^^^^-
|
|
|
|
| |
|
|
|
|
| functions in traits cannot be const
|
|
|
|
| help: remove the `const`
|
2017-12-10 19:47:55 +00:00
|
|
|
|
|
|
|
error: aborting due to 2 previous errors
|
|
|
|
|
2018-03-03 14:59:40 +00:00
|
|
|
For more information about this error, try `rustc --explain E0379`.
|