Skip to content
This repository was archived by the owner on Mar 25, 2024. It is now read-only.

Commit a52b7ac

Browse files
committed
Resolve prelude redundant import warnings
warning: the item `FromIterator` is imported redundantly --> src/mapping.rs:10:5 | 10 | use std::iter::FromIterator; | ^^^^^^^^^^^^^^^^^^^^^^^ | ::: nightly-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/std/src/prelude/mod.rs:129:13 | 129 | pub use core::prelude::rust_2021::*; | ------------------------ the item `FromIterator` is already defined here | = note: `#[warn(unused_imports)]` on by default warning: the item `FromIterator` is imported redundantly --> src/value/from.rs:148:5 | 148 | use std::iter::FromIterator; | ^^^^^^^^^^^^^^^^^^^^^^^ | ::: nightly-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/std/src/prelude/mod.rs:129:13 | 129 | pub use core::prelude::rust_2021::*; | ------------------------ the item `FromIterator` is already defined here
1 parent 9e0b8d3 commit a52b7ac

File tree

2 files changed

+0
-3
lines changed

2 files changed

+0
-3
lines changed

src/mapping.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,6 @@ use std::cmp::Ordering;
77
use std::collections::hash_map::DefaultHasher;
88
use std::fmt::{self, Display};
99
use std::hash::{Hash, Hasher};
10-
use std::iter::FromIterator;
1110
use std::mem;
1211

1312
/// A YAML mapping in which the keys and values are both `serde_yaml::Value`.

src/value/from.rs

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -145,8 +145,6 @@ impl<'a, T: Clone + Into<Value>> From<&'a [T]> for Value {
145145
}
146146
}
147147

148-
use std::iter::FromIterator;
149-
150148
impl<T: Into<Value>> FromIterator<T> for Value {
151149
/// Convert an iteratable type to a YAML sequence
152150
///

0 commit comments

Comments
 (0)