about summary refs log tree commit diff
diff options
context:
space:
mode:
authorMichael Howell <michael@notriddle.com>2021-12-24 13:23:03 -0700
committerMichael Howell <michael@notriddle.com>2021-12-24 13:23:03 -0700
commit551829b6adcaf78a92a8c6faabcf1fbe4e71e14b (patch)
treee87844f0abb2294f95a379447952e5ed5c0b2e98
parent489296d82561f596c278e90edc10eb56168ab623 (diff)
downloadrust-551829b6adcaf78a92a8c6faabcf1fbe4e71e14b.tar.gz
rust-551829b6adcaf78a92a8c6faabcf1fbe4e71e14b.zip
rustdoc: remove unused Hash impl
-rw-r--r--src/librustdoc/clean/types.rs13
1 files changed, 2 insertions, 11 deletions
diff --git a/src/librustdoc/clean/types.rs b/src/librustdoc/clean/types.rs
index cb4896fbfd2..fe32b75d668 100644
--- a/src/librustdoc/clean/types.rs
+++ b/src/librustdoc/clean/types.rs
@@ -1,6 +1,6 @@
 use std::cell::RefCell;
 use std::default::Default;
-use std::hash::{Hash, Hasher};
+use std::hash::Hash;
 use std::lazy::SyncOnceCell as OnceCell;
 use std::path::PathBuf;
 use std::rc::Rc;
@@ -904,7 +904,7 @@ impl<I: Iterator<Item = ast::NestedMetaItem> + IntoIterator<Item = ast::NestedMe
 /// Included files are kept separate from inline doc comments so that proper line-number
 /// information can be given when a doctest fails. Sugared doc comments and "raw" doc comments are
 /// kept separate because of issue #42760.
-#[derive(Clone, PartialEq, Eq, Debug, Hash)]
+#[derive(Clone, PartialEq, Eq, Debug)]
 crate struct DocFragment {
     crate span: rustc_span::Span,
     /// The module this doc-comment came from.
@@ -1140,15 +1140,6 @@ impl PartialEq for Attributes {
 
 impl Eq for Attributes {}
 
-impl Hash for Attributes {
-    fn hash<H: Hasher>(&self, hasher: &mut H) {
-        self.doc_strings.hash(hasher);
-        for attr in &self.other_attrs {
-            attr.id.hash(hasher);
-        }
-    }
-}
-
 #[derive(Clone, PartialEq, Eq, Debug, Hash)]
 crate enum GenericBound {
     TraitBound(PolyTrait, hir::TraitBoundModifier),