Remove unnecessary trait bounds

This commit is contained in:
Hanno Braun 2024-03-22 21:26:05 +01:00
parent 3663be0ffc
commit a5f319b82e

View File

@ -30,7 +30,7 @@ impl<T> ObjectSet<T> {
/// Panics, if the iterator contains duplicate `Handle`s. /// Panics, if the iterator contains duplicate `Handle`s.
pub fn new(handles: impl IntoIterator<Item = Handle<T>>) -> Self pub fn new(handles: impl IntoIterator<Item = Handle<T>>) -> Self
where where
T: Debug + Ord, T: Debug,
{ {
let mut added = BTreeSet::new(); let mut added = BTreeSet::new();
let mut inner = Vec::new(); let mut inner = Vec::new();
@ -156,7 +156,7 @@ impl<T> ObjectSet<T> {
replacements: impl IntoIterator<Item = impl Into<Handle<T>>>, replacements: impl IntoIterator<Item = impl Into<Handle<T>>>,
) -> Option<Self> ) -> Option<Self>
where where
T: Debug + Ord, T: Debug,
{ {
let mut iter = self.iter().cloned().peekable(); let mut iter = self.iter().cloned().peekable();
@ -201,7 +201,7 @@ impl<T> Hash for ObjectSet<T> {
impl<O> FromIterator<Handle<O>> for ObjectSet<O> impl<O> FromIterator<Handle<O>> for ObjectSet<O>
where where
O: Debug + Ord, O: Debug,
{ {
fn from_iter<T: IntoIterator<Item = Handle<O>>>(handles: T) -> Self { fn from_iter<T: IntoIterator<Item = Handle<O>>>(handles: T) -> Self {
Self::new(handles) Self::new(handles)