2023-12-18 10:55:55 -06:00
|
|
|
error: `~const` can only be applied to `#[const_trait]` traits
|
2023-08-13 04:02:31 -05:00
|
|
|
--> $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-12-18 10:55:55 -06:00
|
|
|
error: `~const` can only be applied to `#[const_trait]` traits
|
2023-08-13 04:02:31 -05:00
|
|
|
--> $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-12-18 10:55:55 -06:00
|
|
|
error: `~const` can only be applied to `#[const_trait]` traits
|
2023-08-13 04:02:31 -05:00
|
|
|
--> $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,
|
|
|
|
| ^^^^^^^^^^
|
|
|
|
|
2023-12-18 10:55:55 -06:00
|
|
|
error: `~const` can only be applied to `#[const_trait]` traits
|
2023-08-13 04:02:31 -05:00
|
|
|
--> $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
|
|
|
|