@@ -14,110 +14,145 @@ error: `~const` can only be applied to `#[const_trait]` traits
1414 --> $DIR/fn_trait_refs.rs:14:8
1515 |
1616LL | T: ~const Fn<()> + ~const Destruct,
17- | ^^^^^^
17+ | ^^^^^^ can't be applied to `Fn`
18+ |
19+ note: `Fn` can't be used with `~const` because it isn't annotated with `#[const_trait]`
20+ --> $SRC_DIR/core/src/ops/function.rs:LL:COL
1821
1922error: `~const` can only be applied to `#[const_trait]` traits
2023 --> $DIR/fn_trait_refs.rs:14:8
2124 |
2225LL | T: ~const Fn<()> + ~const Destruct,
23- | ^^^^^^
26+ | ^^^^^^ can't be applied to `Fn`
2427 |
28+ note: `Fn` can't be used with `~const` because it isn't annotated with `#[const_trait]`
29+ --> $SRC_DIR/core/src/ops/function.rs:LL:COL
2530 = note: duplicate diagnostic emitted due to `-Z deduplicate-diagnostics=no`
2631
2732error: `~const` can only be applied to `#[const_trait]` traits
2833 --> $DIR/fn_trait_refs.rs:14:8
2934 |
3035LL | T: ~const Fn<()> + ~const Destruct,
31- | ^^^^^^
36+ | ^^^^^^ can't be applied to `Fn`
3237 |
38+ note: `Fn` can't be used with `~const` because it isn't annotated with `#[const_trait]`
39+ --> $SRC_DIR/core/src/ops/function.rs:LL:COL
3340 = note: duplicate diagnostic emitted due to `-Z deduplicate-diagnostics=no`
3441
3542error: `~const` can only be applied to `#[const_trait]` traits
3643 --> $DIR/fn_trait_refs.rs:21:8
3744 |
3845LL | T: ~const FnMut<()> + ~const Destruct,
39- | ^^^^^^
46+ | ^^^^^^ can't be applied to `FnMut`
47+ |
48+ note: `FnMut` can't be used with `~const` because it isn't annotated with `#[const_trait]`
49+ --> $SRC_DIR/core/src/ops/function.rs:LL:COL
4050
4151error: `~const` can only be applied to `#[const_trait]` traits
4252 --> $DIR/fn_trait_refs.rs:21:8
4353 |
4454LL | T: ~const FnMut<()> + ~const Destruct,
45- | ^^^^^^
55+ | ^^^^^^ can't be applied to `FnMut`
4656 |
57+ note: `FnMut` can't be used with `~const` because it isn't annotated with `#[const_trait]`
58+ --> $SRC_DIR/core/src/ops/function.rs:LL:COL
4759 = note: duplicate diagnostic emitted due to `-Z deduplicate-diagnostics=no`
4860
4961error: `~const` can only be applied to `#[const_trait]` traits
5062 --> $DIR/fn_trait_refs.rs:21:8
5163 |
5264LL | T: ~const FnMut<()> + ~const Destruct,
53- | ^^^^^^
65+ | ^^^^^^ can't be applied to `FnMut`
5466 |
67+ note: `FnMut` can't be used with `~const` because it isn't annotated with `#[const_trait]`
68+ --> $SRC_DIR/core/src/ops/function.rs:LL:COL
5569 = note: duplicate diagnostic emitted due to `-Z deduplicate-diagnostics=no`
5670
5771error: `~const` can only be applied to `#[const_trait]` traits
5872 --> $DIR/fn_trait_refs.rs:28:8
5973 |
6074LL | T: ~const FnOnce<()>,
61- | ^^^^^^
75+ | ^^^^^^ can't be applied to `FnOnce`
76+ |
77+ note: `FnOnce` can't be used with `~const` because it isn't annotated with `#[const_trait]`
78+ --> $SRC_DIR/core/src/ops/function.rs:LL:COL
6279
6380error: `~const` can only be applied to `#[const_trait]` traits
6481 --> $DIR/fn_trait_refs.rs:28:8
6582 |
6683LL | T: ~const FnOnce<()>,
67- | ^^^^^^
84+ | ^^^^^^ can't be applied to `FnOnce`
6885 |
86+ note: `FnOnce` can't be used with `~const` because it isn't annotated with `#[const_trait]`
87+ --> $SRC_DIR/core/src/ops/function.rs:LL:COL
6988 = note: duplicate diagnostic emitted due to `-Z deduplicate-diagnostics=no`
7089
7190error: `~const` can only be applied to `#[const_trait]` traits
7291 --> $DIR/fn_trait_refs.rs:28:8
7392 |
7493LL | T: ~const FnOnce<()>,
75- | ^^^^^^
94+ | ^^^^^^ can't be applied to `FnOnce`
7695 |
96+ note: `FnOnce` can't be used with `~const` because it isn't annotated with `#[const_trait]`
97+ --> $SRC_DIR/core/src/ops/function.rs:LL:COL
7798 = note: duplicate diagnostic emitted due to `-Z deduplicate-diagnostics=no`
7899
79100error: `~const` can only be applied to `#[const_trait]` traits
80101 --> $DIR/fn_trait_refs.rs:35:8
81102 |
82103LL | T: ~const Fn<()> + ~const Destruct,
83- | ^^^^^^
104+ | ^^^^^^ can't be applied to `Fn`
105+ |
106+ note: `Fn` can't be used with `~const` because it isn't annotated with `#[const_trait]`
107+ --> $SRC_DIR/core/src/ops/function.rs:LL:COL
84108
85109error: `~const` can only be applied to `#[const_trait]` traits
86110 --> $DIR/fn_trait_refs.rs:35:8
87111 |
88112LL | T: ~const Fn<()> + ~const Destruct,
89- | ^^^^^^
113+ | ^^^^^^ can't be applied to `Fn`
90114 |
115+ note: `Fn` can't be used with `~const` because it isn't annotated with `#[const_trait]`
116+ --> $SRC_DIR/core/src/ops/function.rs:LL:COL
91117 = note: duplicate diagnostic emitted due to `-Z deduplicate-diagnostics=no`
92118
93119error: `~const` can only be applied to `#[const_trait]` traits
94120 --> $DIR/fn_trait_refs.rs:35:8
95121 |
96122LL | T: ~const Fn<()> + ~const Destruct,
97- | ^^^^^^
123+ | ^^^^^^ can't be applied to `Fn`
98124 |
125+ note: `Fn` can't be used with `~const` because it isn't annotated with `#[const_trait]`
126+ --> $SRC_DIR/core/src/ops/function.rs:LL:COL
99127 = note: duplicate diagnostic emitted due to `-Z deduplicate-diagnostics=no`
100128
101129error: `~const` can only be applied to `#[const_trait]` traits
102130 --> $DIR/fn_trait_refs.rs:49:8
103131 |
104132LL | T: ~const FnMut<()> + ~const Destruct,
105- | ^^^^^^
133+ | ^^^^^^ can't be applied to `FnMut`
134+ |
135+ note: `FnMut` can't be used with `~const` because it isn't annotated with `#[const_trait]`
136+ --> $SRC_DIR/core/src/ops/function.rs:LL:COL
106137
107138error: `~const` can only be applied to `#[const_trait]` traits
108139 --> $DIR/fn_trait_refs.rs:49:8
109140 |
110141LL | T: ~const FnMut<()> + ~const Destruct,
111- | ^^^^^^
142+ | ^^^^^^ can't be applied to `FnMut`
112143 |
144+ note: `FnMut` can't be used with `~const` because it isn't annotated with `#[const_trait]`
145+ --> $SRC_DIR/core/src/ops/function.rs:LL:COL
113146 = note: duplicate diagnostic emitted due to `-Z deduplicate-diagnostics=no`
114147
115148error: `~const` can only be applied to `#[const_trait]` traits
116149 --> $DIR/fn_trait_refs.rs:49:8
117150 |
118151LL | T: ~const FnMut<()> + ~const Destruct,
119- | ^^^^^^
152+ | ^^^^^^ can't be applied to `FnMut`
120153 |
154+ note: `FnMut` can't be used with `~const` because it isn't annotated with `#[const_trait]`
155+ --> $SRC_DIR/core/src/ops/function.rs:LL:COL
121156 = note: duplicate diagnostic emitted due to `-Z deduplicate-diagnostics=no`
122157
123158error[E0277]: the trait bound `fn() -> i32 {one}: const Destruct` is not satisfied
0 commit comments