@@ -267,7 +267,7 @@ fn run_debuginfo_test(config: config, props: TestProps, testfile: &Path) {
267267 // check if each line in props.check_lines appears in the
268268 // output (in order)
269269 let mut i = 0 u;
270- for str:: lines_each ( ProcRes . stdout) |line| {
270+ for str:: each_line ( ProcRes . stdout) |line| {
271271 if props. check_lines [ i] . trim ( ) == line. trim ( ) {
272272 i += 1 u;
273273 }
@@ -297,7 +297,7 @@ fn check_error_patterns(props: TestProps,
297297 let mut next_err_idx = 0 u;
298298 let mut next_err_pat = props. error_patterns [ next_err_idx] ;
299299 let mut done = false ;
300- for str:: lines_each ( ProcRes . stderr) |line| {
300+ for str:: each_line ( ProcRes . stderr) |line| {
301301 if str:: contains ( line, next_err_pat) {
302302 debug ! ( "found error pattern %s" , next_err_pat) ;
303303 next_err_idx += 1 u;
@@ -347,7 +347,7 @@ fn check_expected_errors(expected_errors: ~[errors::ExpectedError],
347347 // filename:line1:col1: line2:col2: *warning:* msg
348348 // where line1:col1: is the starting point, line2:col2:
349349 // is the ending point, and * represents ANSI color codes.
350- for str:: lines_each ( ProcRes . stderr) |line| {
350+ for str:: each_line ( ProcRes . stderr) |line| {
351351 let mut was_expected = false ;
352352 for vec:: eachi( expected_errors) |i, ee| {
353353 if !found_flags[ i] {
@@ -596,8 +596,12 @@ fn split_maybe_args(argstr: Option<~str>) -> ~[~str] {
596596 }
597597
598598 match argstr {
599- Some ( s) => rm_whitespace ( str:: split_char ( s, ' ' ) ) ,
600- None => ~[ ]
599+ Some ( s) => {
600+ let mut ss = ~[ ] ;
601+ for str:: each_split_char( s, ' ' ) |s| { ss. push ( s. to_owned ( ) ) }
602+ rm_whitespace ( ss)
603+ }
604+ None => ~[ ]
601605 }
602606}
603607
0 commit comments