about summary refs log tree commit diff
path: root/src/doc/rustc-dev-guide
diff options
context:
space:
mode:
authorSmittyvb <me@smitop.com>2021-05-13 14:51:43 -0400
committerGitHub <noreply@github.com>2021-05-13 20:51:43 +0200
commit0dc69c529e4b235cdde401275356445f0d89819d (patch)
treef3b9e3bb4ed18dbbb1bcf177bc1cb40fe7a27f5e /src/doc/rustc-dev-guide
parentec88d1f4d2b913d013930f22c217ccdfbe1b8073 (diff)
downloadrust-0dc69c529e4b235cdde401275356445f0d89819d.tar.gz
rust-0dc69c529e4b235cdde401275356445f0d89819d.zip
Document -Zunpretty=thir-tree (#1128)
* document -Zunpretty=thir-tree

* Update position/wording
Diffstat (limited to 'src/doc/rustc-dev-guide')
-rw-r--r--src/doc/rustc-dev-guide/src/thir.md3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/doc/rustc-dev-guide/src/thir.md b/src/doc/rustc-dev-guide/src/thir.md
index b023eb2e2a1..0a0218c6bcf 100644
--- a/src/doc/rustc-dev-guide/src/thir.md
+++ b/src/doc/rustc-dev-guide/src/thir.md
@@ -39,6 +39,9 @@ will be allocated. Dropping this arena will result in the THIR being destroyed,
 which is useful to keep peak memory in check. Having a THIR representation of
 all bodies of a crate in memory at the same time would be very heavy.
 
+You can get a debug representation of the THIR by passing the `-Zunpretty=thir-tree` flag
+to `rustc`.
+
 [thir-docs]: https://doc.rust-lang.org/nightly/nightly-rustc/rustc_mir_build/thir/index.html
 [`thir::Expr`]: https://doc.rust-lang.org/nightly/nightly-rustc/rustc_mir_build/thir/struct.Expr.html
 [`build_thir`]: https://doc.rust-lang.org/nightly/nightly-rustc/rustc_mir_build/thir/fn.build_thir.html