Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Change dependency num to num_traits to shrink dependency tree #76

Merged
merged 1 commit into from
Jan 28, 2018
Merged

Change dependency num to num_traits to shrink dependency tree #76

merged 1 commit into from
Jan 28, 2018

Conversation

LukasKalbertodt
Copy link
Contributor

This crate only uses traits from the num crate. These traits live in
their own crate called num_traits which has way fewer dependencies. By
default, num pulls all its children crates such as num-bigint in. This
in turn brings some heavy crates such as rand into the dependency tree.

I tried to use this crate in a wasm project and rand currently doesn't compile for the new wasm target. That's the way I found out.

Changing dependencies like that is probably a breaking change? Or is it? Since num in turn had num_traits as a dependency? Maybe it's fine...

Btw: awesome crate :)

This crate only uses traits from the `num` crate. These traits live in
their own crate called `num_traits` which has way fewer dependencies. By
default, `num` pulls all its children crates such as `num-bigint` in. This
in turn brings some heavy crates such as `rand` into the dependency tree.
@Ogeon
Copy link
Owner

Ogeon commented Jan 28, 2018

Wow, thanks! Optimizations are always nice!

It may not be a breaking change, but it's going to be bundled with other breaking changes, so it doesn't matter. By the way, I have been super lousy when it comes to getting this crate off the ground again, so I haven't decided if I'm just going to make an intermediate release now or put the RGB changes in there first. Either way, I don't know when I will release it. Not today, at least.

@Ogeon
Copy link
Owner

Ogeon commented Jan 28, 2018

bors r+

bors bot added a commit that referenced this pull request Jan 28, 2018
76: Change dependency `num` to `num_traits` to shrink dependency tree r=Ogeon a=LukasKalbertodt

This crate only uses traits from the `num` crate. These traits live in
their own crate called `num_traits` which has way fewer dependencies. By
default, `num` pulls all its children crates such as `num-bigint` in. This
in turn brings some heavy crates such as `rand` into the dependency tree.

I tried to use this crate in a wasm project and `rand` currently doesn't compile for the new wasm target. That's the way I found out. 

Changing dependencies like that is probably a breaking change? Or is it? Since `num` in turn had `num_traits` as a dependency? Maybe it's fine...

Btw: awesome crate :)
@bors
Copy link
Contributor

bors bot commented Jan 28, 2018

Build succeeded

@bors bors bot merged commit 7ac4c47 into Ogeon:master Jan 28, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants