]> git.proxmox.com Git - rustc.git/blob - src/tools/clippy/tests/ui/ok_expect.stderr
New upstream version 1.74.1+dfsg1
[rustc.git] / src / tools / clippy / tests / ui / ok_expect.stderr
1 error: called `ok().expect()` on a `Result` value
2 --> $DIR/ok_expect.rs:16:5
3 |
4 LL | res.ok().expect("disaster!");
5 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
6 |
7 = help: you can call `expect()` directly on the `Result`
8 = note: `-D clippy::ok-expect` implied by `-D warnings`
9 = help: to override `-D warnings` add `#[allow(clippy::ok_expect)]`
10
11 error: called `ok().expect()` on a `Result` value
12 --> $DIR/ok_expect.rs:23:5
13 |
14 LL | res3.ok().expect("whoof");
15 | ^^^^^^^^^^^^^^^^^^^^^^^^^
16 |
17 = help: you can call `expect()` directly on the `Result`
18
19 error: called `ok().expect()` on a `Result` value
20 --> $DIR/ok_expect.rs:26:5
21 |
22 LL | res4.ok().expect("argh");
23 | ^^^^^^^^^^^^^^^^^^^^^^^^
24 |
25 = help: you can call `expect()` directly on the `Result`
26
27 error: called `ok().expect()` on a `Result` value
28 --> $DIR/ok_expect.rs:29:5
29 |
30 LL | res5.ok().expect("oops");
31 | ^^^^^^^^^^^^^^^^^^^^^^^^
32 |
33 = help: you can call `expect()` directly on the `Result`
34
35 error: called `ok().expect()` on a `Result` value
36 --> $DIR/ok_expect.rs:32:5
37 |
38 LL | res6.ok().expect("meh");
39 | ^^^^^^^^^^^^^^^^^^^^^^^
40 |
41 = help: you can call `expect()` directly on the `Result`
42
43 error: aborting due to 5 previous errors
44