]> git.proxmox.com Git - rustc.git/blob - src/test/ui/tuple/one-tuple.rs
New upstream version 1.52.0~beta.3+dfsg1
[rustc.git] / src / test / ui / tuple / one-tuple.rs
1 // run-pass
2 // Why one-tuples? Because macros.
3
4
5 pub fn main() {
6 match ('c',) {
7 (x,) => {
8 assert_eq!(x, 'c');
9 }
10 }
11 // test the 1-tuple type too
12 let x: (char,) = ('d',);
13 let (y,) = x;
14 assert_eq!(y, 'd');
15 }