File: bitfield_disable_new.stderr

package info (click to toggle)
rust-bitfields 1.0.0-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 436 kB
  • sloc: makefile: 2
file content (17 lines) | stat: -rw-r--r-- 882 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
error[E0599]: no function or associated item named `new` found for struct `Bitfield` in the current scope
  --> tests/compile_error_cases/bitfield_disable_new.rs:12:30
   |
3  | #[bitfield(u64, new = false)]
   | ----------------------------- function or associated item `new` not found for this struct
...
12 |     let bitfield = Bitfield::new(0);
   |                              ^^^ function or associated item not found in `Bitfield`
   |
note: if you're trying to build a new `Bitfield` consider using one of the following associated functions:
      Bitfield::from_bits
      Bitfield::from_bits_with_defaults
  --> tests/compile_error_cases/bitfield_disable_new.rs:3:1
   |
3  | #[bitfield(u64, new = false)]
   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
   = note: this error originates in the attribute macro `bitfield` (in Nightly builds, run with -Z macro-backtrace for more info)