rust-playground
rust-playground copied to clipboard
Allow pretty printing the AST/HIR
It would be really neat if there was an option to dump the AST and HIR representations of programs alongside the option to dump the MIR representation. This would be invaluable when working on the compiler.
cc https://github.com/integer32llc/rust-playground/issues/371
Note: I think the command to use for printing the HIR would be either -Z unpretty=hir (a source-like representation) or -Z unpretty=hir-tree (more like Debug output).
I'm interested in working on this. I'll try to get around to it this weekend.
Note that pretty-printing the AST will probably have to wait until @LeSeulArtichaut implements -Z unpretty=ast.