blob: a999541207d14f995ee86fe5de84e20f684b985f (
plain)
1
2
3
4
5
6
7
8
9
10
|
// run-pass
#![feature(box_syntax)]
// Tests for match as expressions resulting in boxed types
fn test_box() {
let res: Box<_> = match true { true => { box 100 }, _ => panic!() };
assert_eq!(*res, 100);
}
pub fn main() { test_box(); }
|