Function runtime_macros::emulate_derive_macro_expansion
source · pub fn emulate_derive_macro_expansion<'a, F>(
file: File,
macro_paths_and_proc_macro_fns: &[(&'a str, F)]
) -> Result<(), Error>
Expand description
Searches the given Rust source code file for derive macro calls and calls the functions that define how to expand them.
This function behaves just like emulate_functionlike_macro_expansion
, but with derive macros
like #[derive(Foo)]
instead of function-like macros like foo!()
. See that function’s
documentation for details and an example of use.