@@ -446,7 +446,7 @@ impl Config {
446
446
match ( env:: var ( "TARGET" ) , env:: var ( "HOST" ) ) {
447
447
( Ok ( target) , Ok ( host) ) => {
448
448
let kind = if host == target { "HOST" } else { "TARGET" } ;
449
- let target_u = target. replace ( "-" , "_" ) ;
449
+ let target_u = target. replace ( '-' , "_" ) ;
450
450
451
451
self . env_var_os ( & format ! ( "{}_{}" , var_base, target) )
452
452
. or_else ( || self . env_var_os ( & format ! ( "{}_{}" , var_base, target_u) ) )
@@ -802,8 +802,8 @@ impl Library {
802
802
}
803
803
}
804
804
805
- let mut linker_options = words. iter ( ) . filter ( |arg| arg. starts_with ( "-Wl," ) ) ;
806
- while let Some ( option) = linker_options. next ( ) {
805
+ let linker_options = words. iter ( ) . filter ( |arg| arg. starts_with ( "-Wl," ) ) ;
806
+ for option in linker_options {
807
807
let mut pop = false ;
808
808
let mut ld_option = vec ! [ ] ;
809
809
for subopt in option[ 4 ..] . split ( ',' ) {
@@ -829,7 +829,7 @@ impl Library {
829
829
}
830
830
831
831
fn parse_modversion ( & mut self , output : & str ) {
832
- self . version . push_str ( output. lines ( ) . nth ( 0 ) . unwrap ( ) . trim ( ) ) ;
832
+ self . version . push_str ( output. lines ( ) . next ( ) . unwrap ( ) . trim ( ) ) ;
833
833
}
834
834
}
835
835
0 commit comments