File tree Expand file tree Collapse file tree 2 files changed +9
-10
lines changed Expand file tree Collapse file tree 2 files changed +9
-10
lines changed Original file line number Diff line number Diff line change @@ -384,8 +384,7 @@ impl Target {
384384 Path :: new ( target)
385385 } ;
386386
387- let target_path = env:: var_os ( "RUST_TARGET_PATH" )
388- . unwrap_or ( OsString :: from_str ( "" ) ) ;
387+ let target_path = env:: var_os ( "RUST_TARGET_PATH" ) . unwrap_or ( OsString :: from_str ( "" ) ) ;
389388
390389 // FIXME 16351: add a sane default search path?
391390
Original file line number Diff line number Diff line change @@ -1024,14 +1024,14 @@ impl fmt::Display for TryRecvError {
10241024mod test {
10251025 use prelude:: v1:: * ;
10261026
1027- use os ;
1027+ use std :: env ;
10281028 use super :: * ;
10291029 use thread:: Thread ;
10301030
10311031 pub fn stress_factor ( ) -> uint {
1032- match os :: getenv ( "RUST_TEST_STRESS" ) {
1033- Some ( val) => val. parse ( ) . unwrap ( ) ,
1034- None => 1 ,
1032+ match env :: var ( "RUST_TEST_STRESS" ) {
1033+ Ok ( val) => val. parse ( ) . unwrap ( ) ,
1034+ Err ( .. ) => 1 ,
10351035 }
10361036 }
10371037
@@ -1546,14 +1546,14 @@ mod test {
15461546mod sync_tests {
15471547 use prelude:: v1:: * ;
15481548
1549- use os ;
1549+ use std :: env ;
15501550 use thread:: Thread ;
15511551 use super :: * ;
15521552
15531553 pub fn stress_factor ( ) -> uint {
1554- match os :: getenv ( "RUST_TEST_STRESS" ) {
1555- Some ( val) => val. parse ( ) . unwrap ( ) ,
1556- None => 1 ,
1554+ match env :: var ( "RUST_TEST_STRESS" ) {
1555+ Ok ( val) => val. parse ( ) . unwrap ( ) ,
1556+ Err ( .. ) => 1 ,
15571557 }
15581558 }
15591559
You can’t perform that action at this time.
0 commit comments