about summary refs log tree commit diff
path: root/compiler/rustc_mir_transform/src/coverage/counters.rs
diff options
context:
space:
mode:
authorMatthias Krüger <matthias.krueger@famsik.de>2024-10-06 11:06:58 +0200
committerGitHub <noreply@github.com>2024-10-06 11:06:58 +0200
commit11c41ff1651f91de5b33df48a662fcb7c904edae (patch)
treea33d7fd4b9f1db4ab8d5c8821c5477ca92ef023c /compiler/rustc_mir_transform/src/coverage/counters.rs
parentaa546f9a7366029fe97e4f38c4ff4c1c7cd68d02 (diff)
parent7f5548fa8b22bccdadb3cbe7cf4d566a970eeb25 (diff)
downloadrust-11c41ff1651f91de5b33df48a662fcb7c904edae.tar.gz
rust-11c41ff1651f91de5b33df48a662fcb7c904edae.zip
Rollup merge of #131312 - estebank:fn-in-pattern, r=compiler-errors
On function and method calls in patterns, link to the book

```
error: expected a pattern, found an expression
 --> f889.rs:3:13
  |
3 |     let (x, y.drop()) = (1, 2);
  |             ^^^^^^^^ not a pattern
  |
  = note: arbitrary expressions are not allowed in patterns: <https://doc.rust-lang.org/book/ch18-00-patterns.html>

error[E0532]: expected a pattern, found a function call
 --> f889.rs:2:13
  |
2 |     let (x, drop(y)) = (1, 2);
  |             ^^^^ not a tuple struct or tuple variant
  |
  = note: function calls are not allowed in patterns: <https://doc.rust-lang.org/book/ch18-00-patterns.html>
```

Fix #97200.
Diffstat (limited to 'compiler/rustc_mir_transform/src/coverage/counters.rs')
0 files changed, 0 insertions, 0 deletions