2018-08-30 12:18:55 +00:00
|
|
|
//@ run-pass
|
2018-09-25 21:51:35 +00:00
|
|
|
#![allow(unused_mut)]
|
2018-08-31 13:02:01 +00:00
|
|
|
#![allow(non_camel_case_types)]
|
|
|
|
|
2013-12-10 07:16:18 +00:00
|
|
|
enum int_wrapper<'a> {
|
2015-03-26 00:06:52 +00:00
|
|
|
int_wrapper_ctor(&'a isize)
|
2012-03-14 22:41:54 +00:00
|
|
|
}
|
|
|
|
|
2013-02-02 03:43:17 +00:00
|
|
|
pub fn main() {
|
2012-03-14 23:18:33 +00:00
|
|
|
let x = 3;
|
2014-11-06 08:05:53 +00:00
|
|
|
let y = int_wrapper::int_wrapper_ctor(&x);
|
2015-03-26 00:06:52 +00:00
|
|
|
let mut z : &isize;
|
2012-08-06 19:34:08 +00:00
|
|
|
match y {
|
2014-11-06 08:05:53 +00:00
|
|
|
int_wrapper::int_wrapper_ctor(zz) => { z = zz; }
|
2012-03-14 22:41:54 +00:00
|
|
|
}
|
2014-10-15 01:07:11 +00:00
|
|
|
println!("{}", *z);
|
2012-03-14 22:41:54 +00:00
|
|
|
}
|