mirror of
https://github.com/rust-lang/rust
synced 2024-11-05 20:45:15 +00:00
9 lines
214 B
Rust
9 lines
214 B
Rust
//@ check-pass
|
|
fn main() {
|
|
let _: i32 = (match "" {
|
|
"+" => ::std::ops::Add::add,
|
|
"-" => ::std::ops::Sub::sub,
|
|
"<" => |a,b| (a < b) as i32,
|
|
_ => unimplemented!(),
|
|
})(5, 5);
|
|
}
|