Fix tests related to no_std

This commit is contained in:
Seo Sanghyeon 2016-04-20 23:50:43 +09:00
parent 24d86137f5
commit 8ff14bf382
5 changed files with 6 additions and 1 deletions

View File

@ -10,6 +10,7 @@
//! The exponential distribution.
#[cfg(not(test))] // only necessary for no_std
use FloatMath;
use {Rng, Rand};

View File

@ -13,6 +13,7 @@
use self::GammaRepr::*;
use self::ChiSquaredRepr::*;
#[cfg(not(test))] // only necessary for no_std
use FloatMath;
use {Rng, Open01};

View File

@ -17,7 +17,9 @@
//! internally. The `IndependentSample` trait is for generating values
//! that do not need to record state.
#[cfg(not(test))] // only necessary for no_std
use core::num::Float;
use core::marker::PhantomData;
use {Rng, Rand};

View File

@ -10,6 +10,7 @@
//! The normal and derived distributions.
#[cfg(not(test))] // only necessary for no_std
use FloatMath;
use {Rng, Rand, Open01};

View File

@ -28,13 +28,13 @@
#![unstable(feature = "rand",
reason = "use `rand` from crates.io",
issue = "27703")]
#![feature(core_float)]
#![feature(core_intrinsics)]
#![feature(staged_api)]
#![feature(step_by)]
#![feature(custom_attribute)]
#![allow(unused_attributes)]
#![cfg_attr(not(test), feature(core_float))] // only necessary for no_std
#![cfg_attr(test, feature(test, rand))]
#![allow(deprecated)]