mirror of
https://github.com/rust-lang/book.git
synced 2026-12-01 04:58:03 -06:00
Merge pull request #585 from geofft/parse_derive_input
procedural-macros: Rename parse_macro_input to parse_derive_input
This commit is contained in:
@@ -115,7 +115,7 @@ pub fn hello_world(input: TokenStream) -> TokenStream {
|
|||||||
let s = input.to_string();
|
let s = input.to_string();
|
||||||
|
|
||||||
// Parse the string representation
|
// Parse the string representation
|
||||||
let ast = syn::parse_macro_input(&s).unwrap();
|
let ast = syn::parse_derive_input(&s).unwrap();
|
||||||
|
|
||||||
// Build the impl
|
// Build the impl
|
||||||
let gen = impl_hello_world(&ast);
|
let gen = impl_hello_world(&ast);
|
||||||
|
|||||||
Reference in New Issue
Block a user