Logo
Explore Help
Register Sign In
rust-lang/rust
1
0
Fork 0
You've already forked rust
Code Issues Pull Requests Actions 1 Packages Projects Releases Wiki Activity
Files
bae2b51c5f45856eb9c214e5454d2edc48b38c24
rust/tests/ui/for/for-loop-refutable-pattern-error-message.rs

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

4 lines
92 B
Rust
Raw Normal View History

syntax: desugar a `for` loop to a let binding to get better error messages when the pattern is refutable. This means the compiler points directly to the pattern and said that the problem is the pattern being refutable (rather than just saying that some value isn't covered in the `match` as it did previously). Fixes #14390.
2014-05-26 22:01:09 +10:00
fn main() {
hygiene for `for` loops, `if let`, `while let` and some unrelated test cleanups
2015-09-30 12:19:45 +13:00
for &1 in [1].iter() {} //~ ERROR refutable pattern in `for` loop binding
syntax: desugar a `for` loop to a let binding to get better error messages when the pattern is refutable. This means the compiler points directly to the pattern and said that the problem is the pattern being refutable (rather than just saying that some value isn't covered in the `match` as it did previously). Fixes #14390.
2014-05-26 22:01:09 +10:00
}
Reference in New Issue Copy Permalink
Powered by Gitea Version: 1.24.6 Page: 3932ms Template: 3ms
English
Bahasa Indonesia Deutsch English Español Français Gaeilge Italiano Latviešu Magyar nyelv Nederlands Polski Português de Portugal Português do Brasil Suomi Svenska Türkçe Čeština Ελληνικά Български Русский Українська فارسی മലയാളം 日本語 简体中文 繁體中文(台灣) 繁體中文(香港) 한국어
Licenses API