2017-03-23 16:13:01 +01:00
|
|
|
// Test that overloaded calls work with zero arity closures
|
|
|
|
|
|
|
|
fn main() {
|
2019-05-30 10:58:30 +02:00
|
|
|
let functions: [Box<dyn Fn() -> Option<()>>; 1] = [Box::new(|| None)];
|
2017-03-23 16:13:01 +01:00
|
|
|
|
2018-11-26 15:31:53 +01:00
|
|
|
let _val: Option<Vec<()>> = functions.iter().map(|f| (*f)()).collect();
|
2017-03-23 16:13:01 +01:00
|
|
|
}
|