|
1 | 1 | error: bitfield!: Field invalid_range has type u8, which doesn't match the number of bits (9) that are being used for it |
2 | | - --> tests/no_compile/invalid_field_range.rs:6:20 |
| 2 | + --> tests/no_compile/invalid_field_range.rs:7:20 |
3 | 3 | | |
4 | | -6 | invalid_range: u8, |
| 4 | +7 | invalid_range: u8, |
5 | 5 | | ^^ |
| 6 | + |
| 7 | +error[E0599]: no method named `with_c` found for struct `PartialTest<true, true, false>` in the current scope |
| 8 | + --> tests/no_compile/invalid_field_range.rs:30:59 |
| 9 | + | |
| 10 | +10 | #[bitfield(u8)] |
| 11 | + | --------------- method `with_c` not found for this struct |
| 12 | +... |
| 13 | +30 | Test::builder().with_a(u4::new(1)).with_b(u4::new(1)).with_c(true).build(); |
| 14 | + | ^^^^^^ method not found in `PartialTest<true, true, false>` |
| 15 | + | |
| 16 | + = note: the method was found for |
| 17 | + - `PartialTest<false, b, false>` |
| 18 | +help: one of the expressions' fields has a method of the same name |
| 19 | + | |
| 20 | +30 | Test::builder().with_a(u4::new(1)).with_b(u4::new(1)).value.with_c(true).build(); |
| 21 | + | ++++++ |
| 22 | + |
| 23 | +error[E0599]: no method named `build` found for struct `PartialTest<false, false, true>` in the current scope |
| 24 | + --> tests/no_compile/invalid_field_range.rs:31:34 |
| 25 | + | |
| 26 | +10 | #[bitfield(u8)] |
| 27 | + | --------------- method `build` not found for this struct |
| 28 | +... |
| 29 | +31 | Test::builder().with_c(true).build(); |
| 30 | + | ^^^^^ method not found in `PartialTest<false, false, true>` |
| 31 | + | |
| 32 | + = note: the method was found for |
| 33 | + - `PartialTest<true, true, false>` |
| 34 | + |
| 35 | +error[E0599]: no function or associated item named `builder` found for struct `Test2` in the current scope |
| 36 | + --> tests/no_compile/invalid_field_range.rs:32:12 |
| 37 | + | |
| 38 | +20 | #[bitfield(u8)] |
| 39 | + | --------------- function or associated item `builder` not found for this struct |
| 40 | +... |
| 41 | +32 | Test2::builder().with_a(u4::new(1)).with_b(u4::new(1)).build(); |
| 42 | + | ^^^^^^^ function or associated item not found in `Test2` |
| 43 | + | |
| 44 | +note: if you're trying to build a new `Test2`, consider using `Test2::new_with_raw_value` which returns `Test2` |
| 45 | + --> tests/no_compile/invalid_field_range.rs:21:8 |
| 46 | + | |
| 47 | +21 | struct Test2 { |
| 48 | + | ^^^^^ |
0 commit comments