]> git.lizzy.rs Git - rust.git/blob - tests/ui/unboxed-closures/unboxed-closures-cross-crate.rs
Rollup merge of #106244 - atouchet:readme3, r=workingjubilee
[rust.git] / tests / ui / unboxed-closures / unboxed-closures-cross-crate.rs
1 // run-pass
2 #![allow(non_camel_case_types)]
3
4 // Test that unboxed closures work with cross-crate inlining
5 // Acts as a regression test for #16790, #18378 and #18543
6
7 // aux-build:unboxed-closures-cross-crate.rs
8
9 extern crate unboxed_closures_cross_crate as ubcc;
10
11 fn main() {
12     assert_eq!(ubcc::has_closures(), 2_usize);
13     assert_eq!(ubcc::has_generic_closures(2_usize, 3_usize), 5_usize);
14 }