]> git.lizzy.rs Git - rust.git/blobdiff - library/core/src/fmt/mod.rs
Rollup merge of #105682 - thomcc:expose-ptr-fmt, r=RalfJung
[rust.git] / library / core / src / fmt / mod.rs
index 122da675f7e439463feed95d44c92de422341100..5f4a666de928439750910fc044105108d7c7a612 100644 (file)
@@ -2471,8 +2471,8 @@ fn fmt(&self, f: &mut Formatter<'_>) -> Result {
 #[stable(feature = "rust1", since = "1.0.0")]
 impl<T: ?Sized> Pointer for *const T {
     fn fmt(&self, f: &mut Formatter<'_>) -> Result {
-        // Cast is needed here because `.addr()` requires `T: Sized`.
-        pointer_fmt_inner((*self as *const ()).addr(), f)
+        // Cast is needed here because `.expose_addr()` requires `T: Sized`.
+        pointer_fmt_inner((*self as *const ()).expose_addr(), f)
     }
 }