зеркало из https://github.com/mozilla/gecko-dev.git
ba3445b026
MozReview-Commit-ID: GXlQVJ0sPfj --HG-- rename : third_party/rust/num-traits/.cargo-checksum.json => third_party/rust/num-traits-0.1.41/.cargo-checksum.json rename : third_party/rust/num-traits/Cargo.toml => third_party/rust/num-traits-0.1.41/Cargo.toml rename : third_party/rust/num-traits/src/bounds.rs => third_party/rust/num-traits-0.1.41/src/bounds.rs rename : third_party/rust/num-traits/src/cast.rs => third_party/rust/num-traits-0.1.41/src/cast.rs rename : third_party/rust/num-traits/src/float.rs => third_party/rust/num-traits-0.1.41/src/float.rs rename : third_party/rust/num-traits/src/identities.rs => third_party/rust/num-traits-0.1.41/src/identities.rs rename : third_party/rust/num-traits/src/int.rs => third_party/rust/num-traits-0.1.41/src/int.rs rename : third_party/rust/num-traits/src/lib.rs => third_party/rust/num-traits-0.1.41/src/lib.rs rename : third_party/rust/num-traits/src/ops/checked.rs => third_party/rust/num-traits-0.1.41/src/ops/checked.rs rename : third_party/rust/num-traits/src/ops/wrapping.rs => third_party/rust/num-traits-0.1.41/src/ops/wrapping.rs rename : third_party/rust/num-traits/src/pow.rs => third_party/rust/num-traits-0.1.41/src/pow.rs rename : third_party/rust/num-traits/src/sign.rs => third_party/rust/num-traits-0.1.41/src/sign.rs extra : rebase_source : dd540770f739ee41eca8099fa2f8a886f3d4e7c2 |
||
---|---|---|
.. | ||
ci | ||
src | ||
.cargo-checksum.json | ||
.travis.yml | ||
Cargo.toml | ||
LICENSE-APACHE | ||
LICENSE-MIT | ||
README.md | ||
RELEASES.md | ||
bors.toml |
README.md
num-traits
Numeric traits for generic mathematics in Rust.
Usage
Add this to your Cargo.toml
:
[dependencies]
num-traits = "0.2"
and this to your crate root:
extern crate num_traits;
Features
This crate can be used without the standard library (#![no_std]
) by disabling
the default std
feature. Use this in Cargo.toml
:
[dependencies.num-traits]
version = "0.2"
default-features = false
The Float
and Real
traits are only available when std
is enabled.
Releases
Release notes are available in RELEASES.md.
Compatibility
The num-traits
crate is tested for rustc 1.8 and greater.