]> git.lizzy.rs Git - rust.git/blob - tests/ui/trivially_copy_pass_by_ref.stderr
Addition `manual_map` test for `unsafe` blocks
[rust.git] / tests / ui / trivially_copy_pass_by_ref.stderr
1 error: this argument (N byte) is passed by reference, but would be more efficient if passed by value (limit: N byte)
2   --> $DIR/trivially_copy_pass_by_ref.rs:47:11
3    |
4 LL | fn bad(x: &u32, y: &Foo, z: &Baz) {}
5    |           ^^^^ help: consider passing by value instead: `u32`
6    |
7 note: the lint level is defined here
8   --> $DIR/trivially_copy_pass_by_ref.rs:4:9
9    |
10 LL | #![deny(clippy::trivially_copy_pass_by_ref)]
11    |         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
12
13 error: this argument (N byte) is passed by reference, but would be more efficient if passed by value (limit: N byte)
14   --> $DIR/trivially_copy_pass_by_ref.rs:47:20
15    |
16 LL | fn bad(x: &u32, y: &Foo, z: &Baz) {}
17    |                    ^^^^ help: consider passing by value instead: `Foo`
18
19 error: this argument (N byte) is passed by reference, but would be more efficient if passed by value (limit: N byte)
20   --> $DIR/trivially_copy_pass_by_ref.rs:47:29
21    |
22 LL | fn bad(x: &u32, y: &Foo, z: &Baz) {}
23    |                             ^^^^ help: consider passing by value instead: `Baz`
24
25 error: this argument (N byte) is passed by reference, but would be more efficient if passed by value (limit: N byte)
26   --> $DIR/trivially_copy_pass_by_ref.rs:54:12
27    |
28 LL |     fn bad(&self, x: &u32, y: &Foo, z: &Baz) {}
29    |            ^^^^^ help: consider passing by value instead: `self`
30
31 error: this argument (N byte) is passed by reference, but would be more efficient if passed by value (limit: N byte)
32   --> $DIR/trivially_copy_pass_by_ref.rs:54:22
33    |
34 LL |     fn bad(&self, x: &u32, y: &Foo, z: &Baz) {}
35    |                      ^^^^ help: consider passing by value instead: `u32`
36
37 error: this argument (N byte) is passed by reference, but would be more efficient if passed by value (limit: N byte)
38   --> $DIR/trivially_copy_pass_by_ref.rs:54:31
39    |
40 LL |     fn bad(&self, x: &u32, y: &Foo, z: &Baz) {}
41    |                               ^^^^ help: consider passing by value instead: `Foo`
42
43 error: this argument (N byte) is passed by reference, but would be more efficient if passed by value (limit: N byte)
44   --> $DIR/trivially_copy_pass_by_ref.rs:54:40
45    |
46 LL |     fn bad(&self, x: &u32, y: &Foo, z: &Baz) {}
47    |                                        ^^^^ help: consider passing by value instead: `Baz`
48
49 error: this argument (N byte) is passed by reference, but would be more efficient if passed by value (limit: N byte)
50   --> $DIR/trivially_copy_pass_by_ref.rs:56:16
51    |
52 LL |     fn bad2(x: &u32, y: &Foo, z: &Baz) {}
53    |                ^^^^ help: consider passing by value instead: `u32`
54
55 error: this argument (N byte) is passed by reference, but would be more efficient if passed by value (limit: N byte)
56   --> $DIR/trivially_copy_pass_by_ref.rs:56:25
57    |
58 LL |     fn bad2(x: &u32, y: &Foo, z: &Baz) {}
59    |                         ^^^^ help: consider passing by value instead: `Foo`
60
61 error: this argument (N byte) is passed by reference, but would be more efficient if passed by value (limit: N byte)
62   --> $DIR/trivially_copy_pass_by_ref.rs:56:34
63    |
64 LL |     fn bad2(x: &u32, y: &Foo, z: &Baz) {}
65    |                                  ^^^^ help: consider passing by value instead: `Baz`
66
67 error: this argument (N byte) is passed by reference, but would be more efficient if passed by value (limit: N byte)
68   --> $DIR/trivially_copy_pass_by_ref.rs:58:35
69    |
70 LL |     fn bad_issue7518(self, other: &Self) {}
71    |                                   ^^^^^ help: consider passing by value instead: `Self`
72
73 error: this argument (N byte) is passed by reference, but would be more efficient if passed by value (limit: N byte)
74   --> $DIR/trivially_copy_pass_by_ref.rs:70:16
75    |
76 LL |     fn bad2(x: &u32, y: &Foo, z: &Baz) {}
77    |                ^^^^ help: consider passing by value instead: `u32`
78
79 error: this argument (N byte) is passed by reference, but would be more efficient if passed by value (limit: N byte)
80   --> $DIR/trivially_copy_pass_by_ref.rs:70:25
81    |
82 LL |     fn bad2(x: &u32, y: &Foo, z: &Baz) {}
83    |                         ^^^^ help: consider passing by value instead: `Foo`
84
85 error: this argument (N byte) is passed by reference, but would be more efficient if passed by value (limit: N byte)
86   --> $DIR/trivially_copy_pass_by_ref.rs:70:34
87    |
88 LL |     fn bad2(x: &u32, y: &Foo, z: &Baz) {}
89    |                                  ^^^^ help: consider passing by value instead: `Baz`
90
91 error: this argument (N byte) is passed by reference, but would be more efficient if passed by value (limit: N byte)
92   --> $DIR/trivially_copy_pass_by_ref.rs:74:34
93    |
94 LL |     fn trait_method(&self, _foo: &Foo);
95    |                                  ^^^^ help: consider passing by value instead: `Foo`
96
97 error: this argument (N byte) is passed by reference, but would be more efficient if passed by value (limit: N byte)
98   --> $DIR/trivially_copy_pass_by_ref.rs:106:21
99    |
100 LL |     fn foo_never(x: &i32) {
101    |                     ^^^^ help: consider passing by value instead: `i32`
102
103 error: this argument (N byte) is passed by reference, but would be more efficient if passed by value (limit: N byte)
104   --> $DIR/trivially_copy_pass_by_ref.rs:111:15
105    |
106 LL |     fn foo(x: &i32) {
107    |               ^^^^ help: consider passing by value instead: `i32`
108
109 error: aborting due to 17 previous errors
110