You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This crate makes use of features so that "you don't pay for what you don't use" and to support no_std while allowing for extensions that require the standard library. This is good, but it can be beginner unfriendly. The readme should include a brief overview of the features this crate provides with a beginner friendly presentation.
The text was updated successfully, but these errors were encountered:
Sure, would you like to write that up? The current features are:
std enables the full standard library (on by default)
bigint-std enables BigRational using std (on by default)
bigint enables BigRational using just core and alloc (requires Rust 1.36+)
serde implements Deserialize and Serialize for Ratio<T>
Technically, cargo will accept num-bigint as a feature here too for the optional dependency, but it doesn't actually enable anything in num-rational. I'm now thinking we should simplify that one -- package renaming can let us have just bigint and our added bigint-std, or we can go the other way to full num-bigint and add explicit num-bigint-std instead. Thoughts?
I ran into this myself. I started writing a custom serializer for a Rational type and then realized that it already existed. But I could find no mention of the serde feature anywhere (except by reading the code). Do you want me to submit a PR for a change to the docs?
This crate makes use of features so that "you don't pay for what you don't use" and to support no_std while allowing for extensions that require the standard library. This is good, but it can be beginner unfriendly. The readme should include a brief overview of the features this crate provides with a beginner friendly presentation.
The text was updated successfully, but these errors were encountered: