@@ -469,28 +469,28 @@ impl LangString {
469469 ) ;
470470
471471 for token in tokens {
472- match token {
472+ match token. trim ( ) {
473473 "" => { } ,
474474 "should_panic" => {
475475 data. should_panic = true ;
476476 seen_rust_tags = seen_other_tags == false ;
477477 }
478- "no_run" => { data. no_run = true ; seen_rust_tags = seen_other_tags == false ; }
479- "ignore" => { data. ignore = true ; seen_rust_tags = seen_other_tags == false ; }
478+ "no_run" => { data. no_run = true ; seen_rust_tags = ! seen_other_tags; }
479+ "ignore" => { data. ignore = true ; seen_rust_tags = ! seen_other_tags; }
480480 "rust" => { data. rust = true ; seen_rust_tags = true ; }
481481 "test_harness" => {
482482 data. test_harness = true ;
483- seen_rust_tags = seen_other_tags == false || seen_rust_tags == true ;
483+ seen_rust_tags = ! seen_other_tags || seen_rust_tags;
484484 }
485485 "compile_fail" if allow_compile_fail => {
486486 data. compile_fail = true ;
487- seen_rust_tags = seen_other_tags == false || seen_rust_tags == true ;
487+ seen_rust_tags = ! seen_other_tags || seen_rust_tags;
488488 data. no_run = true ;
489489 }
490490 x if allow_error_code_check && x. starts_with ( "E" ) && x. len ( ) == 5 => {
491491 if let Ok ( _) = x[ 1 ..] . parse :: < u32 > ( ) {
492492 data. error_codes . push ( x. to_owned ( ) ) ;
493- seen_rust_tags = seen_other_tags == false || seen_rust_tags == true ;
493+ seen_rust_tags = ! seen_other_tags || seen_rust_tags;
494494 } else {
495495 seen_other_tags = true ;
496496 }
@@ -680,6 +680,7 @@ mod tests {
680680 t ( "{.example .rust}" , false , false , false , true , false , false , Vec :: new ( ) ) ;
681681 t ( "{.test_harness .rust}" , false , false , false , true , true , false , Vec :: new ( ) ) ;
682682 t ( "text, no_run" , false , true , false , false , false , false , Vec :: new ( ) ) ;
683+ t ( "text,no_run" , false , true , false , false , false , false , Vec :: new ( ) ) ;
683684 }
684685
685686 #[ test]
0 commit comments