Go to file
Trevor Spiteri 51c83a7b02 check for repr(transparent) in build.rs 2018-08-10 20:35:09 +02:00
src check for repr(transparent) in build.rs 2018-08-10 20:35:09 +02:00
.gitignore version 0.0.0 2018-08-09 20:02:34 +02:00
Cargo.toml depend on typenum 1.3 2018-08-10 20:05:51 +02:00
LICENSE-APACHE version 0.0.0 2018-08-09 20:02:34 +02:00
LICENSE-MIT version 0.0.0 2018-08-09 20:02:34 +02:00
README.md update top level docs 2018-08-10 20:30:03 +02:00
build.rs check for repr(transparent) in build.rs 2018-08-10 20:35:09 +02:00

README.md

Fixed-point numbers

The fixed crate provides fixed-point numbers. Currently it uses the typenum crate for the fractional bit count; it is planned to move to const generics when they are implemented by the Rust compiler.

The crate provides unsigned fixed-point numbers FixedU8, FixedU16, FixedU32, FixedU64 and FixedU128, and signed fixed-point numbers FixedI8, FixedI16, FixedI32, FixedI64 and FixedI128.

Using the fixed crate

The fixed crate is available on crates.io. To use it in your crate, add it as a dependency inside Cargo.toml:

[dependencies]
fixed = "0.0.1"

You also need to declare it by adding this to your crate root (usually lib.rs or main.rs):

extern crate fixed;

License

This crate is free software: you can redistribute it and/or modify it under the terms of either

at your option.

Contribution

Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in the work by you, as defined in the Apache License, Version 2.0, shall be dual licensed as above, without any additional terms or conditions.