]> git.lizzy.rs Git - rust.git/blob - src/test/ui/mir/mir_static_subtype.rs
Rollup merge of #101388 - compiler-errors:issue-101376, r=fee1-dead
[rust.git] / src / test / ui / mir / mir_static_subtype.rs
1 // run-pass
2 // Test that subtyping the body of a static doesn't cause an ICE.
3
4 fn foo(_ : &()) {}
5 static X: fn(&'static ()) = foo;
6
7 fn main() {
8     let _ = X;
9 }