]> git.lizzy.rs Git - rust.git/blob - src/tools/clippy/tests/ui/if_then_panic.stderr
Merge commit 'cb7915b00c235e9b5861564f3be78dba330980ee' into clippyup
[rust.git] / src / tools / clippy / tests / ui / if_then_panic.stderr
1 error: only a `panic!` in `if`-then statement
2   --> $DIR/if_then_panic.rs:19:5
3    |
4 LL | /     if !a.is_empty() {
5 LL | |         panic!("qaqaq{:?}", a);
6 LL | |     }
7    | |_____^ help: try: `assert!(a.is_empty(), "qaqaq{:?}", a);`
8    |
9    = note: `-D clippy::if-then-panic` implied by `-D warnings`
10
11 error: only a `panic!` in `if`-then statement
12   --> $DIR/if_then_panic.rs:22:5
13    |
14 LL | /     if !a.is_empty() {
15 LL | |         panic!("qwqwq");
16 LL | |     }
17    | |_____^ help: try: `assert!(a.is_empty(), "qwqwq");`
18
19 error: aborting due to 2 previous errors
20