Skip to content

Commit 4cbc322

Browse files
committed
fix(clippy): clippy fixes
1 parent 12b2fd2 commit 4cbc322

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

src/entry.rs

+4-4
Original file line numberDiff line numberDiff line change
@@ -172,7 +172,7 @@ impl KdlEntry {
172172
// but just in case.
173173
let s = x.value_repr.trim();
174174
// convert raw strings to new format
175-
let s = s.strip_prefix("r").unwrap_or(s);
175+
let s = s.strip_prefix('r').unwrap_or(s);
176176
let s = if crate::value::is_plain_ident(val) {
177177
val.to_string()
178178
} else if s
@@ -186,16 +186,16 @@ impl KdlEntry {
186186
} else {
187187
// `"` -> `"""` but also extra newlines need to be
188188
// added because v2 strips the first and last ones.
189-
let s = s.replacen("\"", "\"\"\"\n", 1);
189+
let s = s.replacen('\"', "\"\"\"\n", 1);
190190
s.chars()
191191
.rev()
192192
.collect::<String>()
193-
.replacen("\"", "\"\"\"\n", 1)
193+
.replacen('\"', "\"\"\"\n", 1)
194194
.chars()
195195
.rev()
196196
.collect::<String>()
197197
}
198-
} else if !s.starts_with("#") {
198+
} else if !s.starts_with('#') {
199199
// `/` is no longer an escaped char in v2.
200200
s.replace("\\/", "/")
201201
} else {

0 commit comments

Comments
 (0)