libcore: unify gen_<type> methods on rand::RngUtil into the generic gen.
This moves all the basic random value generation into the Rand instances for each type and then removes the `gen_int`, `gen_char` (etc) methods on RngUtil, leaving only the generic `gen` and the more specialised methods. Also, removes some imports that are redundant due to a `use core::prelude::*` statement.
This commit is contained in:
@@ -19,20 +19,9 @@ use getopts;
|
||||
use sort;
|
||||
use term;
|
||||
|
||||
use core::cmp::Eq;
|
||||
|
||||
use core::to_str::ToStr;
|
||||
use core::either::Either;
|
||||
use core::either;
|
||||
use core::io::WriterUtil;
|
||||
use core::io;
|
||||
use core::comm::{stream, SharedChan};
|
||||
use core::option;
|
||||
use core::prelude::*;
|
||||
use core::result;
|
||||
use core::str;
|
||||
use core::task;
|
||||
use core::vec;
|
||||
|
||||
pub mod rustrt {
|
||||
use core::libc::size_t;
|
||||
@@ -608,12 +597,8 @@ pub mod bench {
|
||||
use time::precise_time_ns;
|
||||
use test::{BenchHarness, BenchSamples};
|
||||
use stats::Stats;
|
||||
|
||||
use core::num;
|
||||
use core::prelude::*;
|
||||
use core::rand::RngUtil;
|
||||
use core::rand;
|
||||
use core::u64;
|
||||
use core::vec;
|
||||
|
||||
pub impl BenchHarness {
|
||||
|
||||
|
||||
Reference in New Issue
Block a user