]> git.lizzy.rs Git - rust.git/blob - src/test/ui/functions-closures/fn-coerce-field.rs
Merge commit '0969bc6dde001e01e7e1f58c8ccd7750f8a49ae1' into sync_cg_clif-2021-03-29
[rust.git] / src / test / ui / functions-closures / fn-coerce-field.rs
1 // run-pass
2 #![allow(dead_code)]
3 // pretty-expanded FIXME #23616
4 #![allow(non_camel_case_types)]
5
6 struct r<F> where F: FnOnce() {
7     field: F,
8 }
9
10 pub fn main() {
11     fn f() {}
12     let _i: r<fn()> = r {field: f as fn()};
13 }