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 {
384
384
Path :: new ( target)
385
385
} ;
386
386
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 ( "" ) ) ;
389
388
390
389
// FIXME 16351: add a sane default search path?
391
390
Original file line number Diff line number Diff line change @@ -1024,14 +1024,14 @@ impl fmt::Display for TryRecvError {
1024
1024
mod test {
1025
1025
use prelude:: v1:: * ;
1026
1026
1027
- use os ;
1027
+ use std :: env ;
1028
1028
use super :: * ;
1029
1029
use thread:: Thread ;
1030
1030
1031
1031
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 ,
1035
1035
}
1036
1036
}
1037
1037
@@ -1546,14 +1546,14 @@ mod test {
1546
1546
mod sync_tests {
1547
1547
use prelude:: v1:: * ;
1548
1548
1549
- use os ;
1549
+ use std :: env ;
1550
1550
use thread:: Thread ;
1551
1551
use super :: * ;
1552
1552
1553
1553
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 ,
1557
1557
}
1558
1558
}
1559
1559
You can’t perform that action at this time.
0 commit comments