We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 25f3011 commit cefd5c5Copy full SHA for cefd5c5
src/charwise/builder.rs
@@ -274,7 +274,7 @@ impl CharwiseDoubleArrayAhoCorasickBuilder {
274
for (&label, &child_id) in &s.edges {
275
mapped.push((self.mapper.get(label).unwrap(), child_id));
276
}
277
- mapped.sort_by(|(c1, _), (c2, _)| c1.cmp(c2));
+ mapped.sort_by_key(|x| x.0);
278
279
let base = self.find_base(&mapped, &helper);
280
if self.states.len() <= usize::from_u32(base.get()) {
0 commit comments