nrc / derive-new

derive simple constructor functions for Rust structs
MIT License
525 stars 35 forks source link

Make a new release of what's on the main #63

Closed antimora closed 12 months ago

antimora commented 1 year ago

Kindly requesting to release the latest changes on the main branch. In particular, this PR is missing from the published version 0.5.9.

The main reason why I am asking is because I have wasted several hours trying to track down which package has enabled "std" when in fact I want to disabled for no_std use case. Since features are additive, if any of dependency crates enable std, I cannot use no_std at the top level.

I am getting this type of error, for example:

error[E0433]: failed to resolve: could not find `std` in the list of imported crates
 --> burn-core/src/record/tensor.rs:7:10
  |
7 | #[derive(new, Clone, Debug)]
  |          ^^^ could not find `std` in the list of imported crates
  |
  = note: this error originates in the derive macro `new` (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0433]: failed to resolve: could not find `std` in the list of imported crates
  --> burn-core/src/record/tensor.rs:15:10
   |
15 | #[derive(new, Clone, Debug)]
   |          ^^^ could not find `std` in the list of imported crates
   |
   = note: this error originates in the derive macro `new` (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0433]: failed to resolve: could not find `std` in the list of imported crates
  --> burn-core/src/record/memory.rs:17:10
   |
17 | #[derive(new, Debug, Default, Clone)]
   |          ^^^ could not find `std` in the list of imported crates
   |
   = note: this error originates in the derive macro `new` (in Nightly builds, run with -Z macro-backtrace for more info)
nrc commented 12 months ago

I've published 0.6 with these changes. Sorry for the delay!