File tree Expand file tree Collapse file tree 1 file changed +4
-4
lines changed
regex-automata/src/nfa/thompson Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -1471,13 +1471,13 @@ impl fmt::Debug for Inner {
1471
1471
}
1472
1472
let pattern_len = self . start_pattern . len ( ) ;
1473
1473
if pattern_len > 1 {
1474
- writeln ! ( f, "" ) ?;
1474
+ writeln ! ( f) ?;
1475
1475
for pid in 0 ..pattern_len {
1476
1476
let sid = self . start_pattern [ pid] ;
1477
1477
writeln ! ( f, "START({:06?}): {:?}" , pid, sid. as_usize( ) ) ?;
1478
1478
}
1479
1479
}
1480
- writeln ! ( f, "" ) ?;
1480
+ writeln ! ( f) ?;
1481
1481
writeln ! (
1482
1482
f,
1483
1483
"transition equivalence classes: {:?}" ,
@@ -1819,7 +1819,7 @@ impl SparseTransitions {
1819
1819
& self ,
1820
1820
unit : alphabet:: Unit ,
1821
1821
) -> Option < StateID > {
1822
- unit. as_u8 ( ) . map_or ( None , |byte| self . matches_byte ( byte) )
1822
+ unit. as_u8 ( ) . and_then ( |byte| self . matches_byte ( byte) )
1823
1823
}
1824
1824
1825
1825
/// This follows the matching transition for a particular byte.
@@ -1909,7 +1909,7 @@ impl DenseTransitions {
1909
1909
& self ,
1910
1910
unit : alphabet:: Unit ,
1911
1911
) -> Option < StateID > {
1912
- unit. as_u8 ( ) . map_or ( None , |byte| self . matches_byte ( byte) )
1912
+ unit. as_u8 ( ) . and_then ( |byte| self . matches_byte ( byte) )
1913
1913
}
1914
1914
1915
1915
/// This follows the matching transition for a particular byte.
You can’t perform that action at this time.
0 commit comments