mirror of
https://github.com/pezkuwichain/serde.git
synced 2026-04-22 14:57:59 +00:00
Resolve manual_string_new pedantic clippy lint
warning: empty String is being created manually
--> test_suite/tests/test_annotations.rs:2280:29
|
2280 | let data = Data::C { t: "".to_string() };
| ^^^^^^^^^^^^^^ help: consider using: `String::new()`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#manual_string_new
= note: `-W clippy::manual-string-new` implied by `-W clippy::pedantic`
This commit is contained in:
@@ -2277,7 +2277,7 @@ fn test_internally_tagged_enum_with_skipped_conflict() {
|
||||
},
|
||||
}
|
||||
|
||||
let data = Data::C { t: "".to_string() };
|
||||
let data = Data::C { t: String::new() };
|
||||
|
||||
assert_tokens(
|
||||
&data,
|
||||
|
||||
Reference in New Issue
Block a user