Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
ttrpc-codegen: Fix clippy error manual_find
Got: error: manual implementation of `Iterator::find` --> src/parser.rs:354:9 | 354 | / for c in alphabet.chars() { 355 | | if self.next_char_if_eq(c) { 356 | | return Some(c); 357 | | } 358 | | } 359 | | None | |____________^ help: replace with an iterator: `alphabet.chars().find(|&c| self.next_char_if_eq(c))` | = note: `-D clippy::manual-find` implied by `-D warnings` = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#manual_find This commit will fix the problem. Signed-off-by: Tim Zhang <[email protected]>
- Loading branch information