blob: f4576229864b8adee0e9b20352c45e7beef6de78 [file] [log] [blame] [edit]
//@ run-pass
struct Test<T: ?Sized>(T);
fn main() {
let x = Test([1,2,3]);
let x : &Test<[i32]> = &x;
let & ref _y = x;
// Make sure binding to a fat pointer behind a reference
// still works
let slice = &[1,2,3];
let x = Test(&slice);
let Test(&_slice) = x;
}