]> git.lizzy.rs Git - rust.git/blob - src/tools/clippy/tests/ui/trivially_copy_pass_by_ref.stderr
Auto merge of #76019 - pietroalbini:rollup-1tkgdnd, r=pietroalbini
[rust.git] / src / tools / clippy / 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:51: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:51: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:51: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:58: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:58: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:58: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:58: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:60: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:60: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:60: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:72:16
69    |
70 LL |     fn bad2(x: &u32, y: &Foo, z: &Baz) {}
71    |                ^^^^ help: consider passing by value instead: `u32`
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:72:25
75    |
76 LL |     fn bad2(x: &u32, y: &Foo, z: &Baz) {}
77    |                         ^^^^ help: consider passing by value instead: `Foo`
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:72:34
81    |
82 LL |     fn bad2(x: &u32, y: &Foo, z: &Baz) {}
83    |                                  ^^^^ help: consider passing by value instead: `Baz`
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:76:34
87    |
88 LL |     fn trait_method(&self, _foo: &Foo);
89    |                                  ^^^^ help: consider passing by value instead: `Foo`
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:80:37
93    |
94 LL |     fn trait_method2(&self, _color: &Color);
95    |                                     ^^^^^^ help: consider passing by value instead: `Color`
96
97 error: aborting due to 15 previous errors
98