1 // Check that when making a ref mut binding with type `&mut T`, the
2 // type `T` must match precisely the type `U` of the value being
3 // matched, and in particular cannot be some supertype of `U`. Issue
4 // #23116. This test focuses on a `let`.
9 fn bar<'a>(&'a mut self) -> &'a mut &'a i32 {
10 let ref mut x = self.0;
11 x //~ ERROR mismatched types