rust/src/librustc_parse
Mazdak Farrokhzad 6c6d45c6e7
Rollup merge of #69236 - Centril:mut-parens-at-recovery, r=estebank
parse: recover `mut (x @ y)` as `(mut x @ mut y)`.

Follow up to https://github.com/rust-lang/rust/pull/68992#discussion_r376829749 and https://github.com/rust-lang/rust/pull/63945.

Specifically, when given `let mut (x @ y)` we recover with `let (mut x @ mut y)` as the suggestion:

```rust
error: `mut` must be attached to each individual binding
  --> $DIR/mut-patterns.rs:12:9
   |
LL |     let mut (x @ y) = 0;
   |         ^^^^^^^^^^^ help: add `mut` to each binding: `(mut x @ mut y)`
   |
   = note: `mut` may be followed by `variable` and `variable @ pattern`
```

r? @matthewjasper @estebank
2020-02-18 22:16:31 +01:00
..
lexer Invert control in struct_lint_level. 2020-02-11 19:47:40 +10:00
parser Rollup merge of #69236 - Centril:mut-parens-at-recovery, r=estebank 2020-02-18 22:16:31 +01:00
Cargo.toml syntax::print -> new crate rustc_ast_pretty 2020-02-01 18:59:49 +01:00
config.rs Rollup merge of #69057 - Centril:clean-expand, r=petrochenkov 2020-02-13 21:28:05 +01:00
lib.rs parser: Remove Options from unnormalized tokens 2020-02-17 22:12:39 +03:00
validate_attr.rs Run RustFmt 2020-02-11 19:49:01 +10:00