]>
git.proxmox.com Git - rustc.git/blob - tests/ui/unsized/unsized-tuple-impls.rs
3 #![feature(unsized_tuple_coercion)]
5 use std
::collections
::HashSet
;
8 let x
: &(i32, i32, [i32]) = &(0, 1, [2, 3]);
9 let y
: &(i32, i32, [i32]) = &(0, 1, [2, 3, 4]);
12 assert_eq
!(a
, [x
, y
]);
14 assert_eq
!(&format
!("{:?}", a
), "[(0, 1, [2, 3]), (0, 1, [2, 3, 4])]");
16 let mut h
= HashSet
::new();
19 assert
!(h
.contains(x
));
20 assert
!(h
.contains(y
));