isaacholt100 / bnum

Arbitrary, fixed size numeric types that extend the functionality of primitive numeric types in Rust.
https://crates.io/crates/bnum
Other
73 stars 10 forks source link

bnum overrides features chosen for num-integer and num-traits #10

Closed lrubasze closed 1 year ago

lrubasze commented 1 year ago

I need to use num-traits or num-integer without default features (no_std in fact), eg.

Cargo.toml:

...
[dependencies]
num-traits = { version = "0.2.15", default-features = false }
num-integer = { version = "0.1.45", default-features = false }
bnum = { version = "0.3", default-features = false, features = ["numtraits"] }
...

In such configuration bnum overrides my settings and sets num-integer and num-traits to default (with std).

lrubasze commented 1 year ago

It looks like other dependencies: serde, serde-big-array and rand might also override the features chosen.

isaacholt100 commented 1 year ago

Fixed. All dependencies now have default-features = false, so you should be able to use the new release (v0.4.0) with no_std.

lrubasze commented 1 year ago

thanks for prompt fix and release. really appreciate it 👍 btw. discovered that there is some issue here: https://docs.rs/crate/bnum/latest

image

no idea, what could be the root cause.

isaacholt100 commented 1 year ago

No worries at all, and thanks for pointing this out, I hadn't noticed this.

isaacholt100 commented 1 year ago

Thanks again for mentioning the docs.rs build error, I have now fixed this issue, it was because v0.4.0 didn't compile with the latest version of nightly. v0.5.0 has now been published which fixes this.