File tree Expand file tree Collapse file tree 2 files changed +4
-4
lines changed
Expand file tree Collapse file tree 2 files changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -50,7 +50,7 @@ pub fn derive_non_exhaustive(input: TokenStream) -> TokenStream {
5050 TokenStream :: from ( expanded)
5151}
5252
53- #[ proc_macro_derive( PlaceholderPartialDebug , attributes( placeholder ) ) ]
53+ #[ proc_macro_derive( PlaceholderPartialDebug , attributes( debug_placeholder ) ) ]
5454pub fn derive_placeholder ( input : TokenStream ) -> TokenStream {
5555 let input = parse_macro_input ! ( input as ItemStruct ) ;
5656 let placeholder = match get_placeholder ( & input) {
@@ -117,13 +117,13 @@ fn get_placeholder(input: &ItemStruct) -> Result<Option<String>> {
117117 let placeholders: Vec < _ > = input
118118 . attrs
119119 . iter ( )
120- . filter ( |attribute| attribute. path . is_ident ( "placeholder " ) )
120+ . filter ( |attribute| attribute. path . is_ident ( "debug_placeholder " ) )
121121 . collect ( ) ;
122122
123123 if placeholders. len ( ) > 1 {
124124 return Err ( Error :: new_spanned (
125125 placeholders[ 1 ] ,
126- "More than one placeholder attribute" ,
126+ "More than one debug_placeholder attribute" ,
127127 ) ) ;
128128 }
129129
Original file line number Diff line number Diff line change 8181//! # }
8282//! #
8383//! #[derive(PartialDebug)]
84- //! #[placeholder = "Unknown"]
84+ //! #[debug_placeholder = "Unknown"]
8585//! struct Dog {
8686//! legs: usize,
8787//! eyes: usize,
You can’t perform that action at this time.
0 commit comments