Skip to content

Commit 16f36db

Browse files
Mark min_const_fn_fn_ptr test as gate test
1 parent 50fb9f1 commit 16f36db

File tree

2 files changed

+4
-2
lines changed

2 files changed

+4
-2
lines changed

src/test/ui/consts/min_const_fn/min_const_fn_fn_ptr.rs

+2
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
// gate-test-const_fn_fn_ptr_basics
2+
13
struct HasPtr {
24
field: fn(),
35
}

src/test/ui/consts/min_const_fn/min_const_fn_fn_ptr.stderr

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
error[E0658]: function pointers cannot appear in constant functions
2-
--> $DIR/min_const_fn_fn_ptr.rs:11:5
2+
--> $DIR/min_const_fn_fn_ptr.rs:13:5
33
|
44
LL | x.0.field;
55
| ^^^^^^^^^
@@ -8,7 +8,7 @@ LL | x.0.field;
88
= help: add `#![feature(const_fn_fn_ptr_basics)]` to the crate attributes to enable
99

1010
error[E0658]: function pointers cannot appear in constant functions
11-
--> $DIR/min_const_fn_fn_ptr.rs:14:59
11+
--> $DIR/min_const_fn_fn_ptr.rs:16:59
1212
|
1313
LL | const fn no_inner_dyn_trait_ret() -> Hide { Hide(HasPtr { field }) }
1414
| ^^^^^

0 commit comments

Comments
 (0)