Add comment to new example

This commit is contained in:
Jules Bertholet 2024-05-06 20:44:02 -04:00
parent 1d1d1f4909
commit e222363d4b
No known key found for this signature in database
GPG Key ID: 32034DAFC38C1BFC
1 changed files with 4 additions and 0 deletions

View File

@ -313,6 +313,10 @@ would break:
```rust
let &[[&mut a]] = &[&mut [42]];
// `&mut` in pattern needs to match against either:
// - `&mut` in value at same position (there is none, so not possible)
// - inherited `&mut` (which the "never set default binding mode to `ref mut` behind `&`" rule
// downgrades to `&`)
```
Therefore, we *cannot* delay a decision on this matter.