1
Fork 0

std: Remove {float,f64,f32}::from_str in favor of from_str

Like issue #9209, remove float::{from_str, from_str_radix} in favor of
the two corresponding traits. The same for modules f64 and f32.

New usage is

	from_str::<float>("1.2e34")
This commit is contained in:
blake2-ppc 2013-09-18 02:17:47 +02:00
parent c135cb2683
commit b5d560a9e0
5 changed files with 190 additions and 216 deletions

View file

@ -17,7 +17,6 @@ extern mod extra;
use std::os;
use std::rt;
use std::f64;
use extra::getopts;
use extra::getopts::groups::{optopt, optflag, reqopt};
@ -131,7 +130,7 @@ pub fn parse_config(args: ~[~str]) -> config {
ratchet_noise_percent:
getopts::opt_maybe_str(matches,
"ratchet-noise-percent").map_move(|s|
f64::from_str(s).unwrap()),
from_str::<f64>(s).unwrap()),
runtool: getopts::opt_maybe_str(matches, "runtool"),
rustcflags: getopts::opt_maybe_str(matches, "rustcflags"),
jit: getopts::opt_present(matches, "jit"),