Add a prelude

This prelude contains the sealed public types as well as
the conversions traits.
This commit is contained in:
jean-airoldie 2019-08-03 04:05:47 -04:00
parent dad1cb298c
commit a94621e1d5
1 changed files with 16 additions and 0 deletions

View File

@ -224,6 +224,22 @@ use {
},
};
/// A "prelude" for users of the *fixed* crate.
///
/// This prelude is similar to the standard library's prelude in that you'll
/// almost always want to import its entire contents, but unlike the standard
/// library's prelude you'll have to do so manually:
///
/// ```
/// ##[allow(unused_imports)]
/// use fixed::prelude::*;
/// ```
///
/// The prelude may grow over time as additional items see ubiquitous use.
pub mod prelude {
pub use crate::traits::{FromFixed, ToFixed};
}
#[macro_use]
mod macros_from_to;
#[macro_use]