While building a compiler plugin for compiler plugins, I found that I can use extctxt from current compiler, but rust’s quote!() macros accept (cx, ) and generate very long code.
Compiler plugin - https://github.com/appcore-project/rust-cg
cargo rustc --verbose -- -Z unstable-options --pretty=expanded > expanded.rs
and below is some of generated code.
Token tree regenerated, and then parsed again?