]> git.lizzy.rs Git - rust.git/blob - src/test/ui/structs/struct-base-wrong-type.stderr
00c2e1e0dd518e52a0ee4f91904245b9cd1ede6c
[rust.git] / src / test / ui / structs / struct-base-wrong-type.stderr
1 error[E0308]: mismatched types
2   --> $DIR/struct-base-wrong-type.rs:10:33
3    |
4 LL | static foo: Foo = Foo { a: 2, ..bar };
5    |                                 ^^^ expected struct `Foo`, found struct `Bar`
6    |
7    = note: expected type `Foo`
8               found type `Bar`
9
10 error[E0308]: mismatched types
11   --> $DIR/struct-base-wrong-type.rs:14:35
12    |
13 LL | static foo_i: Foo = Foo { a: 2, ..4 };
14    |                                   ^ expected struct `Foo`, found integer
15    |
16    = note: expected type `Foo`
17               found type `{integer}`
18
19 error[E0308]: mismatched types
20   --> $DIR/struct-base-wrong-type.rs:22:27
21    |
22 LL |     let f = Foo { a: 2, ..b };
23    |                           ^ expected struct `Foo`, found struct `Bar`
24    |
25    = note: expected type `Foo`
26               found type `Bar`
27
28 error[E0308]: mismatched types
29   --> $DIR/struct-base-wrong-type.rs:23:34
30    |
31 LL |     let f__isize = Foo { a: 2, ..4 };
32    |                                  ^ expected struct `Foo`, found integer
33    |
34    = note: expected type `Foo`
35               found type `{integer}`
36
37 error: aborting due to 4 previous errors
38
39 For more information about this error, try `rustc --explain E0308`.