We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents 0f72ce1 + 4582c14 commit cb81b41Copy full SHA for cb81b41
src/libcore/convert/mod.rs
@@ -41,6 +41,7 @@
41
#![stable(feature = "rust1", since = "1.0.0")]
42
43
use crate::fmt;
44
+use crate::hash::{Hash, Hasher};
45
46
mod num;
47
@@ -746,3 +747,10 @@ impl From<!> for Infallible {
746
747
x
748
}
749
750
+
751
+#[stable(feature = "convert_infallible_hash", since = "1.44.0")]
752
+impl Hash for Infallible {
753
+ fn hash<H: Hasher>(&self, _: &mut H) {
754
+ match *self {}
755
+ }
756
+}
0 commit comments