]> git.proxmox.com Git - rustc.git/blame - src/test/ui/binding/match-ref-binding-mut-option.rs
New upstream version 1.67.1+dfsg1
[rustc.git] / src / test / ui / binding / match-ref-binding-mut-option.rs
CommitLineData
b7449926 1// run-pass
c34b1796 2
223e47cc 3pub fn main() {
85aaf69f 4 let mut v = Some(22);
223e47cc
LB
5 match v {
6 None => {}
7 Some(ref mut p) => { *p += 1; }
8 }
970d7e83 9 assert_eq!(v, Some(23));
223e47cc 10}