about summary refs log tree commit diff
path: root/src/doc/rustc-dev-guide
diff options
context:
space:
mode:
authorAlex Kitchens <alexcameron98@gmail.com>2018-05-17 12:53:11 -0500
committerWho? Me?! <mark-i-m@users.noreply.github.com>2018-05-20 19:08:25 -0500
commit82c1fa408988090fee48e05b56e1c1e6bd2e8484 (patch)
tree8c4b78fb6d17b3f53f43ac680c6bab0d1efef40f /src/doc/rustc-dev-guide
parentbcb81eb491620d9d1daedf9746e70b1a94159c81 (diff)
downloadrust-82c1fa408988090fee48e05b56e1c1e6bd2e8484.tar.gz
rust-82c1fa408988090fee48e05b56e1c1e6bd2e8484.zip
Define HIR more specifically
IR is a foreign acronym to me, so having it fully expressed in the beginning as Intermediate Representation helps me comprehend the subject.
Diffstat (limited to 'src/doc/rustc-dev-guide')
-rw-r--r--src/doc/rustc-dev-guide/src/high-level-overview.md5
-rw-r--r--src/doc/rustc-dev-guide/src/hir.md10
2 files changed, 8 insertions, 7 deletions
diff --git a/src/doc/rustc-dev-guide/src/high-level-overview.md b/src/doc/rustc-dev-guide/src/high-level-overview.md
index 9f3b63a549e..be396054bda 100644
--- a/src/doc/rustc-dev-guide/src/high-level-overview.md
+++ b/src/doc/rustc-dev-guide/src/high-level-overview.md
@@ -104,8 +104,8 @@ take:
       nodes, and hence may strip things out of the AST as well.
 3. **Lowering to HIR**
     - Once name resolution completes, we convert the AST into the HIR,
-      or "high-level IR". The HIR is defined in `src/librustc/hir/`;
-      that module also includes the lowering code.
+      or "[high-level intermediate representation]". The HIR is defined in
+      `src/librustc/hir/`; that module also includes the lowering code.
     - The HIR is a lightly desugared variant of the AST. It is more processed
       than the AST and more suitable for the analyses that follow.
       It is **not** required to match the syntax of the Rust language.
@@ -138,3 +138,4 @@ take:
 
 
 [query model]: query.html
+[high-level intermediate representation]: hir.html
diff --git a/src/doc/rustc-dev-guide/src/hir.md b/src/doc/rustc-dev-guide/src/hir.md
index 06ee5e10596..44c4968b13b 100644
--- a/src/doc/rustc-dev-guide/src/hir.md
+++ b/src/doc/rustc-dev-guide/src/hir.md
@@ -1,10 +1,10 @@
 # The HIR
 
-The HIR – "High-level IR" – is the primary IR used in most of rustc. It is a
-compiler-friendly representation of the abstract syntax tree (AST) that is
-generated after parsing, macro expansion, and name resolution.
-Many parts of HIR resemble Rust surface syntax quite closely, with the
-exception that some of Rust's expression forms have been desugared away. For
+The HIR – "High-Level Intermediate Representation" – is the primary IR used in
+most of rustc. It is a compiler-friendly representation of the abstract syntax
+tree (AST) that is generated after parsing, macro expansion, and name
+resolution. Many parts of HIR resemble Rust surface syntax quite closely, with
+the exception that some of Rust's expression forms have been desugared away. For
 example, `for` loops are converted into a `loop` and do not appear in the HIR.
 This makes HIR more amenable to analysis than a normal AST.