mirror of https://github.com/KaiserY/trpl-zh-cn
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
17 lines
533 B
17 lines
533 B
3 years ago
|
$ cargo run
|
||
|
Compiling patterns v0.1.0 (file:///projects/patterns)
|
||
|
warning: irrefutable `if let` pattern
|
||
|
--> src/main.rs:2:8
|
||
|
|
|
||
|
2 | if let x = 5 {
|
||
|
| ^^^^^^^^^
|
||
|
|
|
||
|
= note: this pattern will always match, so the `if let` is useless
|
||
|
= help: consider replacing the `if let` with a `let`
|
||
6 months ago
|
= note: `#[warn(irrefutable_let_patterns)]` on by default
|
||
3 years ago
|
|
||
|
warning: `patterns` (bin "patterns") generated 1 warning
|
||
6 months ago
|
Finished `dev` profile [unoptimized + debuginfo] target(s) in 0.39s
|
||
3 years ago
|
Running `target/debug/patterns`
|
||
|
5
|