]> git.lizzy.rs Git - rust.git/blobdiff - src/libcore/mem/mod.rs
Clean up E0207 explanation
[rust.git] / src / libcore / mem / mod.rs
index 4e8ba8131f7a64707ff3c463897b58406ab8f61b..9eb151cf528a5c3cfea721e5a80ee18fa97fea9b 100644 (file)
@@ -121,7 +121,7 @@ pub fn forget<T>(t: T) {
 ///
 /// [`forget`]: fn.forget.html
 #[inline]
-#[unstable(feature = "forget_unsized", issue = "0")]
+#[unstable(feature = "forget_unsized", issue = "none")]
 pub fn forget_unsized<T: ?Sized>(t: T) {
     // SAFETY: the forget intrinsic could be safe, but there's no point in making it safe since
     // we'll be implementing this function soon via `ManuallyDrop`
@@ -557,7 +557,7 @@ pub fn swap<T>(x: &mut T, y: &mut T) {
     }
 }
 
-/// Replace `dest` with the default value of `T`, and return the previous `dest` value.
+/// Replaces `dest` with the default value of `T`, returning the previous `dest` value.
 ///
 /// # Examples
 ///
@@ -745,7 +745,7 @@ pub fn replace<T>(dest: &mut T, mut src: T) -> T {
 /// [`Copy`]: ../../std/marker/trait.Copy.html
 #[inline]
 #[stable(feature = "rust1", since = "1.0.0")]
-pub fn drop<T>(_x: T) { }
+pub fn drop<T>(_x: T) {}
 
 /// Interprets `src` as having type `&U`, and then reads `src` without moving
 /// the contained value.
@@ -834,9 +834,7 @@ fn hash<H: hash::Hasher>(&self, state: &mut H) {
 #[stable(feature = "discriminant_value", since = "1.21.0")]
 impl<T> fmt::Debug for Discriminant<T> {
     fn fmt(&self, fmt: &mut fmt::Formatter<'_>) -> fmt::Result {
-        fmt.debug_tuple("Discriminant")
-           .field(&self.0)
-           .finish()
+        fmt.debug_tuple("Discriminant").field(&self.0).finish()
     }
 }