From c0ab1e5f4181e60c1a95d797533c71aadf9c13c5 Mon Sep 17 00:00:00 2001 From: Ngo Iok Ui Date: Tue, 29 Sep 2020 15:32:01 +0800 Subject: [PATCH] RFC42: no_std update --- text/0042-secret-debug-display.md | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/text/0042-secret-debug-display.md b/text/0042-secret-debug-display.md index cdc5397..23df700 100644 --- a/text/0042-secret-debug-display.md +++ b/text/0042-secret-debug-display.md @@ -6,8 +6,8 @@ # Summary This RFC introduces two [procedural macros](https://doc.rust-lang.org/reference/procedural-macros.html), `SecretDebug` -and `SecretDisplay`, to derive the traits [Debug](https://doc.rust-lang.org/std/fmt/trait.Debug.html) and -[Display](https://doc.rust-lang.org/std/fmt/trait.Display.html) for secret material types in order to avoid leaking +and `SecretDisplay`, to derive the traits [Debug](https://doc.rust-lang.org/core/fmt/trait.Debug.html) and +[Display](https://doc.rust-lang.org/core/fmt/trait.Display.html) for secret material types in order to avoid leaking their internals. # Motivation @@ -63,8 +63,8 @@ pub fn derive_secret_debug(input: proc_macro::TokenStream) -> proc_macro::TokenS let expanded = quote! { // The generated implementation. - impl #impl_generics std::fmt::Debug for #name #ty_generics { - fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result { + impl #impl_generics core::fmt::Debug for #name #ty_generics { + fn fmt(&self, f: &mut core::fmt::Formatter<'_>) -> core::fmt::Result { write!(f, "") } }