2023-08-13 04:02:31 -05:00
|
|
|
error: ~const can only be applied to `#[const_trait]` traits
|
|
|
|
--> $DIR/const-closures.rs:8:19
|
2023-07-29 03:20:25 -05:00
|
|
|
|
|
2023-08-13 04:02:31 -05:00
|
|
|
LL | F: ~const FnOnce() -> u8,
|
|
|
|
| ^^^^^^^^^^^^^^
|
2023-07-29 03:20:25 -05:00
|
|
|
|
2023-08-13 04:02:31 -05:00
|
|
|
error: ~const can only be applied to `#[const_trait]` traits
|
|
|
|
--> $DIR/const-closures.rs:9:19
|
2023-07-29 03:20:25 -05:00
|
|
|
|
|
2023-08-13 04:02:31 -05:00
|
|
|
LL | F: ~const FnMut() -> u8,
|
|
|
|
| ^^^^^^^^^^^^^
|
2023-07-29 03:20:25 -05:00
|
|
|
|
2023-08-13 04:02:31 -05:00
|
|
|
error: ~const can only be applied to `#[const_trait]` traits
|
|
|
|
--> $DIR/const-closures.rs:10:19
|
2023-07-29 03:20:25 -05:00
|
|
|
|
|
2023-08-13 04:02:31 -05:00
|
|
|
LL | F: ~const Fn() -> u8,
|
|
|
|
| ^^^^^^^^^^
|
|
|
|
|
|
|
|
error: ~const can only be applied to `#[const_trait]` traits
|
|
|
|
--> $DIR/const-closures.rs:23:27
|
2023-07-29 03:20:25 -05:00
|
|
|
|
|
2023-08-13 04:02:31 -05:00
|
|
|
LL | const fn answer<F: ~const Fn() -> u8>(f: &F) -> u8 {
|
|
|
|
| ^^^^^^^^^^
|
2023-07-29 03:20:25 -05:00
|
|
|
|
2023-08-13 04:02:31 -05:00
|
|
|
error: aborting due to 4 previous errors
|
2023-07-29 03:20:25 -05:00
|
|
|
|