File tree Expand file tree Collapse file tree 1 file changed +3
-6
lines changed
Expand file tree Collapse file tree 1 file changed +3
-6
lines changed Original file line number Diff line number Diff line change @@ -431,12 +431,9 @@ impl<'a> StrftimeItems<'a> {
431431 use Item :: { Literal , Space } ;
432432 use Numeric :: * ;
433433
434- match remainder. chars ( ) . next ( ) {
435- // we are done
436- None => None ,
437-
434+ match remainder. chars ( ) . next ( ) ? {
438435 // the next item is a specifier
439- Some ( '%' ) => {
436+ '%' => {
440437 let original = remainder;
441438 remainder = & remainder[ 1 ..] ;
442439 let mut error_len = 0 ;
@@ -664,7 +661,7 @@ impl<'a> StrftimeItems<'a> {
664661 }
665662
666663 // the next item is space
667- Some ( c ) if c. is_whitespace ( ) => {
664+ c if c. is_whitespace ( ) => {
668665 // `%` is not a whitespace, so `c != '%'` is redundant
669666 let nextspec =
670667 remainder. find ( |c : char | !c. is_whitespace ( ) ) . unwrap_or ( remainder. len ( ) ) ;
You can’t perform that action at this time.
0 commit comments