Skip to content

Commit cc13f82

Browse files
Update item order in test
1 parent 3ba50b3 commit cc13f82

2 files changed

+10
-10
lines changed

tests/ui/type/clarify-error-for-generics-with-default-issue-120785.rs

+3-3
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ fn main() {
55
let c: What<usize, String> = What(1, String::from("meow"));
66
b = c; //~ ERROR mismatched types
77

8-
let mut e: What<usize> = What(5, vec![1, 2, 3]);
9-
let f: What<usize, Vec<String>> = What(1, vec![String::from("meow")]);
10-
e = f; //~ ERROR mismatched types
8+
let mut f: What<usize, Vec<String>> = What(1, vec![String::from("meow")]);
9+
let e: What<usize> = What(5, vec![1, 2, 3]);
10+
f = e; //~ ERROR mismatched types
1111
}

tests/ui/type/clarify-error-for-generics-with-default-issue-120785.stderr

+7-7
Original file line numberDiff line numberDiff line change
@@ -13,14 +13,14 @@ LL | b = c;
1313
error[E0308]: mismatched types
1414
--> $DIR/clarify-error-for-generics-with-default-issue-120785.rs:10:9
1515
|
16-
LL | let mut e: What<usize> = What(5, vec![1, 2, 3]);
17-
| ----------- expected due to this type
18-
LL | let f: What<usize, Vec<String>> = What(1, vec![String::from("meow")]);
19-
LL | e = f;
20-
| ^ expected `What`, found `What<usize, Vec<String>>`
16+
LL | let mut f: What<usize, Vec<String>> = What(1, vec![String::from("meow")]);
17+
| ------------------------ expected due to this type
18+
LL | let e: What<usize> = What(5, vec![1, 2, 3]);
19+
LL | f = e;
20+
| ^ expected `What<usize, Vec<String>>`, found `What`
2121
|
22-
= note: expected struct `What<_, Vec<usize>>`
23-
found struct `What<_, Vec<String>>`
22+
= note: expected struct `What<_, Vec<String>>`
23+
found struct `What<_, Vec<usize>>`
2424

2525
error: aborting due to 2 previous errors
2626

0 commit comments

Comments
 (0)