You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: src/test/ui/closures/2229_closure_analysis/migrations/auto_traits.fixed
+1-1
Original file line number
Diff line number
Diff line change
@@ -56,7 +56,7 @@ impl Clone for U {
56
56
fn test_clone_trait() {
57
57
let f = U(S(String::from("Hello World")), T(0));
58
58
let c = || { let _ = &f;
59
-
//~^ ERROR: `Clone` trait implementation for closure, and drop order
59
+
//~^ ERROR: `Clone` trait implementation for closure and drop order
60
60
//~| NOTE: in Rust 2018, this closure would implement `Clone` as `f` implements `Clone`, but in Rust 2021, this closure would no longer implement `Clone` as `f.1` does not implement `Clone`
61
61
//~| NOTE: for more information, see
62
62
//~| HELP: add a dummy let to cause `f` to be fully captured
Copy file name to clipboardExpand all lines: src/test/ui/closures/2229_closure_analysis/migrations/auto_traits.rs
+1-1
Original file line number
Diff line number
Diff line change
@@ -56,7 +56,7 @@ impl Clone for U {
56
56
fntest_clone_trait(){
57
57
let f = U(S(String::from("Hello World")),T(0));
58
58
let c = || {
59
-
//~^ ERROR: `Clone` trait implementation for closure, and drop order
59
+
//~^ ERROR: `Clone` trait implementation for closure and drop order
60
60
//~| NOTE: in Rust 2018, this closure would implement `Clone` as `f` implements `Clone`, but in Rust 2021, this closure would no longer implement `Clone` as `f.1` does not implement `Clone`
61
61
//~| NOTE: for more information, see
62
62
//~| HELP: add a dummy let to cause `f` to be fully captured
Copy file name to clipboardExpand all lines: src/test/ui/closures/2229_closure_analysis/migrations/multi_diagnostics.fixed
+2-2
Original file line number
Diff line number
Diff line change
@@ -21,7 +21,7 @@ fn test_multi_issues() {
21
21
let f1 = U(S(String::from("foo")), T(0));
22
22
let f2 = U(S(String::from("bar")), T(0));
23
23
let c = || { let _ = (&f1, &f2);
24
-
//~^ ERROR: `Clone` trait implementation for closure, and drop order
24
+
//~^ ERROR: `Clone` trait implementation for closure and drop order
25
25
//~| NOTE: in Rust 2018, this closure would implement `Clone` as `f1` implements `Clone`, but in Rust 2021, this closure would no longer implement `Clone` as `f1.0` does not implement `Clone`
26
26
//~| NOTE: for more information, see
27
27
//~| HELP: add a dummy let to cause `f1`, `f2` to be fully captured
let f1 = U1(S(String::from("foo")), T(0), S(String::from("bar")));
86
86
let c = || { let _ = &f1;
87
-
//~^ ERROR: `Clone` trait implementation for closure, and drop order
87
+
//~^ ERROR: `Clone` trait implementation for closure and drop order
88
88
//~| NOTE: in Rust 2018, this closure would implement `Clone` as `f1` implements `Clone`, but in Rust 2021, this closure would no longer implement `Clone` as `f1.0` does not implement `Clone`
89
89
//~| NOTE: for more information, see
90
90
//~| HELP: add a dummy let to cause `f1` to be fully captured
Copy file name to clipboardExpand all lines: src/test/ui/closures/2229_closure_analysis/migrations/multi_diagnostics.rs
+2-2
Original file line number
Diff line number
Diff line change
@@ -21,7 +21,7 @@ fn test_multi_issues() {
21
21
let f1 = U(S(String::from("foo")),T(0));
22
22
let f2 = U(S(String::from("bar")),T(0));
23
23
let c = || {
24
-
//~^ ERROR: `Clone` trait implementation for closure, and drop order
24
+
//~^ ERROR: `Clone` trait implementation for closure and drop order
25
25
//~| NOTE: in Rust 2018, this closure would implement `Clone` as `f1` implements `Clone`, but in Rust 2021, this closure would no longer implement `Clone` as `f1.0` does not implement `Clone`
26
26
//~| NOTE: for more information, see
27
27
//~| HELP: add a dummy let to cause `f1`, `f2` to be fully captured
let f1 = U1(S(String::from("foo")),T(0),S(String::from("bar")));
86
86
let c = || {
87
-
//~^ ERROR: `Clone` trait implementation for closure, and drop order
87
+
//~^ ERROR: `Clone` trait implementation for closure and drop order
88
88
//~| NOTE: in Rust 2018, this closure would implement `Clone` as `f1` implements `Clone`, but in Rust 2021, this closure would no longer implement `Clone` as `f1.0` does not implement `Clone`
89
89
//~| NOTE: for more information, see
90
90
//~| HELP: add a dummy let to cause `f1` to be fully captured
0 commit comments