2018-08-30 14:18:55 +02:00
|
|
|
//@ run-pass
|
2015-02-10 22:52:00 +01:00
|
|
|
#![feature(box_patterns)]
|
2015-01-07 20:32:25 +01:00
|
|
|
|
2013-02-01 19:43:17 -08:00
|
|
|
pub fn main() {
|
2021-08-25 02:39:40 +02:00
|
|
|
match Box::new(100) {
|
2014-05-05 18:56:44 -07:00
|
|
|
box x => {
|
2014-10-14 21:07:11 -04:00
|
|
|
println!("{}", x);
|
2013-05-18 22:02:45 -04:00
|
|
|
assert_eq!(x, 100);
|
2012-06-04 22:56:40 -07:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|