We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
unpretty=hir
unpretty=hir-tree
1 parent 39fcd94 commit 975626cCopy full SHA for 975626c
src/doc/rustc-dev-guide/src/hir-debugging.md
@@ -1,6 +1,13 @@
1
# HIR Debugging
2
3
-The `-Z unpretty=hir-tree` flag will dump out the HIR.
+Use the `-Z unpretty=hir` flag to produce a human-readable representation of the HIR.
4
+For cargo projects this can be done with `cargo rustc -- -Z unpretty=hir`.
5
+This output is useful when you need to see at a glance how your code was desugared and transformed
6
+during AST lowering.
7
+
8
+For a full `Debug` dump of the data in the HIR, use the `-Z unpretty=hir-tree` flag.
9
+This may be useful when you need to see the full structure of the HIR from the perspective of the
10
+compiler.
11
12
If you are trying to correlate `NodeId`s or `DefId`s with source code, the
13
`-Z unpretty=expanded,identified` flag may be useful.
0 commit comments