So for example, I want to do something similar to this:
// my_proc_macro.rs
fn my_proc_macro(filename: &'static str) -> TokenStream {
quote! {
include_str!(#filename)
}
}
// main.rs
const FILENAME: &'static str = "myfile.txt";
let x = my_proc_macro(FILENAME);
I feel like macro expansion is too early for this to work, but I'm open to equivalent hacky solutions.