dbstruct 0.6.0

Build a typed database by defining a struct
Documentation
error[E0277]: the trait bound `CustomType: serde::ser::Serialize` is not satisfied
  --> tests/ui/trait_is_missing.rs:10:12
   |
10 |     field: CustomType,
   |            ^^^^^^^^^^ the trait `serde::ser::Serialize` is not implemented for `CustomType`
   |
   = note: for local types consider adding `#[derive(serde::Serialize)]` to your `CustomType` type
   = note: for types from other crates check whether the crate offers a `serde` feature flag
   = help: the following other types implement trait `serde::ser::Serialize`:
             &'a T
             &'a mut T
             ()
             (T,)
             (T0, T1)
             (T0, T1, T2)
             (T0, T1, T2, T3)
             (T0, T1, T2, T3, T4)
           and $N others
note: required by a bound in `DefaultTrait`
  --> src/wrapper/default_trait.rs
   |
   | pub struct DefaultTrait<T, DS>
   |            ------------ required by a bound in this struct
   | where
   |     T: Serialize + DeserializeOwned + Default,
   |        ^^^^^^^^^ required by this bound in `DefaultTrait`

error[E0277]: the trait bound `CustomType: Default` is not satisfied
  --> tests/ui/trait_is_missing.rs:10:12
   |
10 |     field: CustomType,
   |            ^^^^^^^^^^ the trait `Default` is not implemented for `CustomType`
   |
note: required by a bound in `DefaultTrait`
  --> src/wrapper/default_trait.rs
   |
   | pub struct DefaultTrait<T, DS>
   |            ------------ required by a bound in this struct
   | where
   |     T: Serialize + DeserializeOwned + Default,
   |                                       ^^^^^^^ required by this bound in `DefaultTrait`
help: consider annotating `CustomType` with `#[derive(Default)]`
   |
3  + #[derive(Default)]
4  | struct CustomType {
   |

error[E0277]: the trait bound `for<'de> CustomType: serde::de::Deserialize<'de>` is not satisfied
  --> tests/ui/trait_is_missing.rs:10:12
   |
10 |     field: CustomType,
   |            ^^^^^^^^^^ the trait `for<'de> serde::de::Deserialize<'de>` is not implemented for `CustomType`
   |
   = note: for local types consider adding `#[derive(serde::Deserialize)]` to your `CustomType` type
   = note: for types from other crates check whether the crate offers a `serde` feature flag
   = help: the following other types implement trait `serde::de::Deserialize<'de>`:
             &'a Path
             &'a [u8]
             &'a str
             ()
             (T,)
             (T0, T1)
             (T0, T1, T2)
             (T0, T1, T2, T3)
           and $N others
   = note: required for `CustomType` to implement `serde::de::DeserializeOwned`
note: required by a bound in `DefaultTrait`
  --> src/wrapper/default_trait.rs
   |
   | pub struct DefaultTrait<T, DS>
   |            ------------ required by a bound in this struct
   | where
   |     T: Serialize + DeserializeOwned + Default,
   |                    ^^^^^^^^^^^^^^^^ required by this bound in `DefaultTrait`

error[E0277]: the trait bound `CustomType: serde::ser::Serialize` is not satisfied
 --> tests/ui/trait_is_missing.rs:7:1
  |
7 | #[dbstruct(db=sled)]
  | ^^^^^^^^^^^^^^^^^^^^ the trait `serde::ser::Serialize` is not implemented for `CustomType`
  |
  = note: for local types consider adding `#[derive(serde::Serialize)]` to your `CustomType` type
  = note: for types from other crates check whether the crate offers a `serde` feature flag
  = help: the following other types implement trait `serde::ser::Serialize`:
            &'a T
            &'a mut T
            ()
            (T,)
            (T0, T1)
            (T0, T1, T2)
            (T0, T1, T2, T3)
            (T0, T1, T2, T3, T4)
          and $N others
note: required by a bound in `DefaultTrait::<T, DS>::new`
 --> src/wrapper/default_trait.rs
  |
  |     T: Serialize + DeserializeOwned + Default,
  |        ^^^^^^^^^ required by this bound in `DefaultTrait::<T, DS>::new`
...
  |     pub fn new(ds: DS, key: u8) -> Self {
  |            --- required by a bound in this associated function
  = note: this error originates in the attribute macro `dbstruct` (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0277]: the trait bound `CustomType: Default` is not satisfied
 --> tests/ui/trait_is_missing.rs:7:1
  |
7 | #[dbstruct(db=sled)]
  | ^^^^^^^^^^^^^^^^^^^^ the trait `Default` is not implemented for `CustomType`
  |
note: required by a bound in `DefaultTrait::<T, DS>::new`
 --> src/wrapper/default_trait.rs
  |
  |     T: Serialize + DeserializeOwned + Default,
  |                                       ^^^^^^^ required by this bound in `DefaultTrait::<T, DS>::new`
...
  |     pub fn new(ds: DS, key: u8) -> Self {
  |            --- required by a bound in this associated function
  = note: this error originates in the attribute macro `dbstruct` (in Nightly builds, run with -Z macro-backtrace for more info)
help: consider annotating `CustomType` with `#[derive(Default)]`
  |
3  + #[derive(Default)]
4  | struct CustomType {
   |

error[E0277]: the trait bound `CustomType: serde::de::DeserializeOwned` is not satisfied
 --> tests/ui/trait_is_missing.rs:7:1
  |
7 | #[dbstruct(db=sled)]
  | ^^^^^^^^^^^^^^^^^^^^ the trait `for<'de> serde::de::Deserialize<'de>` is not implemented for `CustomType`
  |
  = help: the following other types implement trait `serde::de::Deserialize<'de>`:
            &'a Path
            &'a [u8]
            &'a str
            ()
            (T,)
            (T0, T1)
            (T0, T1, T2)
            (T0, T1, T2, T3)
          and $N others
  = note: required for `CustomType` to implement `serde::de::DeserializeOwned`
note: required by a bound in `DefaultTrait::<T, DS>::new`
 --> src/wrapper/default_trait.rs
  |
  |     T: Serialize + DeserializeOwned + Default,
  |                    ^^^^^^^^^^^^^^^^ required by this bound in `DefaultTrait::<T, DS>::new`
...
  |     pub fn new(ds: DS, key: u8) -> Self {
  |            --- required by a bound in this associated function
  = note: this error originates in the attribute macro `dbstruct` (in Nightly builds, run with -Z macro-backtrace for more info)