diff options
| author | Unknown <dobbybabee@gmail.com> | 2019-01-31 23:50:55 -0500 |
|---|---|---|
| committer | unknown <unknown@example.com> | 2019-02-01 13:21:19 -0500 |
| commit | 93a856e9d505db2ca3fe3be22ec28a1d97bce84e (patch) | |
| tree | 133c03642fe0f945706e832d136f045d20bf068b | |
| parent | 21e2b13125f50695cc4de10529019ffd1566237f (diff) | |
| download | rust-93a856e9d505db2ca3fe3be22ec28a1d97bce84e.tar.gz rust-93a856e9d505db2ca3fe3be22ec28a1d97bce84e.zip | |
Changing single character string to a character match.
| -rw-r--r-- | clippy_lints/src/functions.rs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/clippy_lints/src/functions.rs b/clippy_lints/src/functions.rs index 0da7e26a1be..7c23503507a 100644 --- a/clippy_lints/src/functions.rs +++ b/clippy_lints/src/functions.rs @@ -189,11 +189,11 @@ impl<'a, 'tcx> Functions { let mut code_in_line; // Skip the surrounding function decl. - let start_brace_idx = match code_snippet.find("{") { + let start_brace_idx = match code_snippet.find('{') { Some(i) => i + 1, None => 0, }; - let end_brace_idx = match code_snippet.find("}") { + let end_brace_idx = match code_snippet.find('}') { Some(i) => i, None => code_snippet.len(), }; |
