|
1 |
| -error: since & implements Copy trait, &Option<&T> can be simplifyied into Option<&T> |
| 1 | +error: since `&` implements the `Copy` trait, `&Option<&T>` can be simplified to `Option<&T>` |
2 | 2 | --> $DIR/ref_option_ref.rs:10:23
|
3 | 3 | |
|
4 | 4 | LL | static REF_THRESHOLD: &Option<&i32> = &Some(&THRESHOLD);
|
5 | 5 | | ^^^^^^^^^^^^^ help: try: `Option<&i32>`
|
6 | 6 | |
|
7 | 7 | = note: `-D clippy::ref-option-ref` implied by `-D warnings`
|
8 | 8 |
|
9 |
| -error: since & implements Copy trait, &Option<&T> can be simplifyied into Option<&T> |
| 9 | +error: since `&` implements the `Copy` trait, `&Option<&T>` can be simplified to `Option<&T>` |
10 | 10 | --> $DIR/ref_option_ref.rs:12:18
|
11 | 11 | |
|
12 | 12 | LL | const REF_CONST: &Option<&i32> = &Some(&CONST_THRESHOLD);
|
13 | 13 | | ^^^^^^^^^^^^^ help: try: `Option<&i32>`
|
14 | 14 |
|
15 |
| -error: since & implements Copy trait, &Option<&T> can be simplifyied into Option<&T> |
| 15 | +error: since `&` implements the `Copy` trait, `&Option<&T>` can be simplified to `Option<&T>` |
16 | 16 | --> $DIR/ref_option_ref.rs:14:25
|
17 | 17 | |
|
18 | 18 | LL | type RefOptRefU32<'a> = &'a Option<&'a u32>;
|
19 | 19 | | ^^^^^^^^^^^^^^^^^^^ help: try: `Option<&'a u32>`
|
20 | 20 |
|
21 |
| -error: since & implements Copy trait, &Option<&T> can be simplifyied into Option<&T> |
| 21 | +error: since `&` implements the `Copy` trait, `&Option<&T>` can be simplified to `Option<&T>` |
22 | 22 | --> $DIR/ref_option_ref.rs:15:25
|
23 | 23 | |
|
24 | 24 | LL | type RefOptRef<'a, T> = &'a Option<&'a T>;
|
25 | 25 | | ^^^^^^^^^^^^^^^^^ help: try: `Option<&'a T>`
|
26 | 26 |
|
27 |
| -error: since & implements Copy trait, &Option<&T> can be simplifyied into Option<&T> |
| 27 | +error: since `&` implements the `Copy` trait, `&Option<&T>` can be simplified to `Option<&T>` |
28 | 28 | --> $DIR/ref_option_ref.rs:17:14
|
29 | 29 | |
|
30 | 30 | LL | fn foo(data: &Option<&u32>) {}
|
31 | 31 | | ^^^^^^^^^^^^^ help: try: `Option<&u32>`
|
32 | 32 |
|
33 |
| -error: since & implements Copy trait, &Option<&T> can be simplifyied into Option<&T> |
| 33 | +error: since `&` implements the `Copy` trait, `&Option<&T>` can be simplified to `Option<&T>` |
34 | 34 | --> $DIR/ref_option_ref.rs:19:23
|
35 | 35 | |
|
36 | 36 | LL | fn bar(data: &u32) -> &Option<&u32> {
|
37 | 37 | | ^^^^^^^^^^^^^ help: try: `Option<&u32>`
|
38 | 38 |
|
39 |
| -error: since & implements Copy trait, &Option<&T> can be simplifyied into Option<&T> |
| 39 | +error: since `&` implements the `Copy` trait, `&Option<&T>` can be simplified to `Option<&T>` |
40 | 40 | --> $DIR/ref_option_ref.rs:24:11
|
41 | 41 | |
|
42 | 42 | LL | data: &'a Option<&'a u32>,
|
43 | 43 | | ^^^^^^^^^^^^^^^^^^^ help: try: `Option<&'a u32>`
|
44 | 44 |
|
45 |
| -error: since & implements Copy trait, &Option<&T> can be simplifyied into Option<&T> |
| 45 | +error: since `&` implements the `Copy` trait, `&Option<&T>` can be simplified to `Option<&T>` |
46 | 46 | --> $DIR/ref_option_ref.rs:27:32
|
47 | 47 | |
|
48 | 48 | LL | struct StructTupleRef<'a>(u32, &'a Option<&'a u32>);
|
49 | 49 | | ^^^^^^^^^^^^^^^^^^^ help: try: `Option<&'a u32>`
|
50 | 50 |
|
51 |
| -error: since & implements Copy trait, &Option<&T> can be simplifyied into Option<&T> |
| 51 | +error: since `&` implements the `Copy` trait, `&Option<&T>` can be simplified to `Option<&T>` |
52 | 52 | --> $DIR/ref_option_ref.rs:31:14
|
53 | 53 | |
|
54 | 54 | LL | Variant2(&'a Option<&'a u32>),
|
55 | 55 | | ^^^^^^^^^^^^^^^^^^^ help: try: `Option<&'a u32>`
|
56 | 56 |
|
57 |
| -error: since & implements Copy trait, &Option<&T> can be simplifyied into Option<&T> |
| 57 | +error: since `&` implements the `Copy` trait, `&Option<&T>` can be simplified to `Option<&T>` |
58 | 58 | --> $DIR/ref_option_ref.rs:40:14
|
59 | 59 | |
|
60 | 60 | LL | type A = &'static Option<&'static Self>;
|
61 | 61 | | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `Option<&'static Self>`
|
62 | 62 |
|
63 |
| -error: since & implements Copy trait, &Option<&T> can be simplifyied into Option<&T> |
| 63 | +error: since `&` implements the `Copy` trait, `&Option<&T>` can be simplified to `Option<&T>` |
64 | 64 | --> $DIR/ref_option_ref.rs:46:12
|
65 | 65 | |
|
66 | 66 | LL | let x: &Option<&u32> = &None;
|
|
0 commit comments