]> git.lizzy.rs Git - rust.git/blobdiff - tests/ui/trivially_copy_pass_by_ref.stderr
Auto merge of #3603 - xfix:random-state-lint, r=phansch
[rust.git] / tests / ui / trivially_copy_pass_by_ref.stderr
index 2026d4c00d8f1d87c0803827c3a45474ec4da617..6f2967bc392df72036f6dcdfc5e9c70ebe3a9a59 100644 (file)
@@ -1,82 +1,94 @@
 error: this argument is passed by reference, but would be more efficient if passed by value
-  --> $DIR/trivially_copy_pass_by_ref.rs:52:11
+  --> $DIR/trivially_copy_pass_by_ref.rs:56:11
    |
-52 | fn bad(x: &u32, y: &Foo, z: &Baz) {
+LL | fn bad(x: &u32, y: &Foo, z: &Baz) {}
    |           ^^^^ help: consider passing by value instead: `u32`
    |
    = note: `-D clippy::trivially-copy-pass-by-ref` implied by `-D warnings`
 
 error: this argument is passed by reference, but would be more efficient if passed by value
-  --> $DIR/trivially_copy_pass_by_ref.rs:52:20
+  --> $DIR/trivially_copy_pass_by_ref.rs:56:20
    |
-52 | fn bad(x: &u32, y: &Foo, z: &Baz) {
+LL | fn bad(x: &u32, y: &Foo, z: &Baz) {}
    |                    ^^^^ help: consider passing by value instead: `Foo`
 
 error: this argument is passed by reference, but would be more efficient if passed by value
-  --> $DIR/trivially_copy_pass_by_ref.rs:52:29
+  --> $DIR/trivially_copy_pass_by_ref.rs:56:29
    |
-52 | fn bad(x: &u32, y: &Foo, z: &Baz) {
+LL | fn bad(x: &u32, y: &Foo, z: &Baz) {}
    |                             ^^^^ help: consider passing by value instead: `Baz`
 
 error: this argument is passed by reference, but would be more efficient if passed by value
-  --> $DIR/trivially_copy_pass_by_ref.rs:62:12
+  --> $DIR/trivially_copy_pass_by_ref.rs:63:12
    |
-62 |     fn bad(&self, x: &u32, y: &Foo, z: &Baz) {
+LL |     fn bad(&self, x: &u32, y: &Foo, z: &Baz) {}
    |            ^^^^^ help: consider passing by value instead: `self`
 
 error: this argument is passed by reference, but would be more efficient if passed by value
-  --> $DIR/trivially_copy_pass_by_ref.rs:62:22
+  --> $DIR/trivially_copy_pass_by_ref.rs:63:22
    |
-62 |     fn bad(&self, x: &u32, y: &Foo, z: &Baz) {
+LL |     fn bad(&self, x: &u32, y: &Foo, z: &Baz) {}
    |                      ^^^^ help: consider passing by value instead: `u32`
 
 error: this argument is passed by reference, but would be more efficient if passed by value
-  --> $DIR/trivially_copy_pass_by_ref.rs:62:31
+  --> $DIR/trivially_copy_pass_by_ref.rs:63:31
    |
-62 |     fn bad(&self, x: &u32, y: &Foo, z: &Baz) {
+LL |     fn bad(&self, x: &u32, y: &Foo, z: &Baz) {}
    |                               ^^^^ help: consider passing by value instead: `Foo`
 
 error: this argument is passed by reference, but would be more efficient if passed by value
-  --> $DIR/trivially_copy_pass_by_ref.rs:62:40
+  --> $DIR/trivially_copy_pass_by_ref.rs:63:40
    |
-62 |     fn bad(&self, x: &u32, y: &Foo, z: &Baz) {
+LL |     fn bad(&self, x: &u32, y: &Foo, z: &Baz) {}
    |                                        ^^^^ help: consider passing by value instead: `Baz`
 
 error: this argument is passed by reference, but would be more efficient if passed by value
   --> $DIR/trivially_copy_pass_by_ref.rs:65:16
    |
-65 |     fn bad2(x: &u32, y: &Foo, z: &Baz) {
+LL |     fn bad2(x: &u32, y: &Foo, z: &Baz) {}
    |                ^^^^ help: consider passing by value instead: `u32`
 
 error: this argument is passed by reference, but would be more efficient if passed by value
   --> $DIR/trivially_copy_pass_by_ref.rs:65:25
    |
-65 |     fn bad2(x: &u32, y: &Foo, z: &Baz) {
+LL |     fn bad2(x: &u32, y: &Foo, z: &Baz) {}
    |                         ^^^^ help: consider passing by value instead: `Foo`
 
 error: this argument is passed by reference, but would be more efficient if passed by value
   --> $DIR/trivially_copy_pass_by_ref.rs:65:34
    |
-65 |     fn bad2(x: &u32, y: &Foo, z: &Baz) {
+LL |     fn bad2(x: &u32, y: &Foo, z: &Baz) {}
    |                                  ^^^^ help: consider passing by value instead: `Baz`
 
 error: this argument is passed by reference, but would be more efficient if passed by value
-  --> $DIR/trivially_copy_pass_by_ref.rs:79:16
+  --> $DIR/trivially_copy_pass_by_ref.rs:77:16
    |
-79 |     fn bad2(x: &u32, y: &Foo, z: &Baz) {
+LL |     fn bad2(x: &u32, y: &Foo, z: &Baz) {}
    |                ^^^^ help: consider passing by value instead: `u32`
 
 error: this argument is passed by reference, but would be more efficient if passed by value
-  --> $DIR/trivially_copy_pass_by_ref.rs:79:25
+  --> $DIR/trivially_copy_pass_by_ref.rs:77:25
    |
-79 |     fn bad2(x: &u32, y: &Foo, z: &Baz) {
+LL |     fn bad2(x: &u32, y: &Foo, z: &Baz) {}
    |                         ^^^^ help: consider passing by value instead: `Foo`
 
 error: this argument is passed by reference, but would be more efficient if passed by value
-  --> $DIR/trivially_copy_pass_by_ref.rs:79:34
+  --> $DIR/trivially_copy_pass_by_ref.rs:77:34
    |
-79 |     fn bad2(x: &u32, y: &Foo, z: &Baz) {
+LL |     fn bad2(x: &u32, y: &Foo, z: &Baz) {}
    |                                  ^^^^ help: consider passing by value instead: `Baz`
 
-error: aborting due to 13 previous errors
+error: this argument is passed by reference, but would be more efficient if passed by value
+  --> $DIR/trivially_copy_pass_by_ref.rs:81:34
+   |
+LL |     fn trait_method(&self, _foo: &Foo);
+   |                                  ^^^^ help: consider passing by value instead: `Foo`
+
+error: this argument is passed by reference, but would be more efficient if passed by value
+  --> $DIR/trivially_copy_pass_by_ref.rs:85:37
+   |
+LL |     fn trait_method2(&self, _color: &Color);
+   |                                     ^^^^^^ help: consider passing by value instead: `Color`
+
+error: aborting due to 15 previous errors