@@ -200,7 +200,29 @@ LL | const fn union_access_can_be_const() {
200200 | +++++
201201
202202error: this could be a `const fn`
203- --> tests/ui/missing_const_for_fn/could_be_const.rs:152:9
203+ --> tests/ui/missing_const_for_fn/could_be_const.rs:146:9
204+ |
205+ LL | extern "C" fn c() {}
206+ | ^^^^^^^^^^^^^^^^^^^^
207+ |
208+ help: make the function `const`
209+ |
210+ LL | const extern "C" fn c() {}
211+ | +++++
212+
213+ error: this could be a `const fn`
214+ --> tests/ui/missing_const_for_fn/could_be_const.rs:150:9
215+ |
216+ LL | extern fn implicit_c() {}
217+ | ^^^^^^^^^^^^^^^^^^^^^^^^^
218+ |
219+ help: make the function `const`
220+ |
221+ LL | const extern fn implicit_c() {}
222+ | +++++
223+
224+ error: this could be a `const fn`
225+ --> tests/ui/missing_const_for_fn/could_be_const.rs:167:9
204226 |
205227LL | / pub fn new(strings: Vec<String>) -> Self {
206228LL | | Self { strings }
@@ -213,7 +235,7 @@ LL | pub const fn new(strings: Vec<String>) -> Self {
213235 | +++++
214236
215237error: this could be a `const fn`
216- --> tests/ui/missing_const_for_fn/could_be_const.rs:157 :9
238+ --> tests/ui/missing_const_for_fn/could_be_const.rs:172 :9
217239 |
218240LL | / pub fn empty() -> Self {
219241LL | | Self { strings: Vec::new() }
@@ -226,7 +248,7 @@ LL | pub const fn empty() -> Self {
226248 | +++++
227249
228250error: this could be a `const fn`
229- --> tests/ui/missing_const_for_fn/could_be_const.rs:168 :9
251+ --> tests/ui/missing_const_for_fn/could_be_const.rs:183 :9
230252 |
231253LL | / pub fn new(text: String) -> Self {
232254LL | | let vec = Vec::new();
@@ -239,5 +261,5 @@ help: make the function `const`
239261LL | pub const fn new(text: String) -> Self {
240262 | +++++
241263
242- error: aborting due to 17 previous errors
264+ error: aborting due to 19 previous errors
243265
0 commit comments