Skip to content

Commit ea6d646

Browse files
committed
reflow
1 parent 57e49f1 commit ea6d646

1 file changed

Lines changed: 9 additions & 10 deletions

File tree

src/mir/construction.md

Lines changed: 9 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -12,16 +12,16 @@ list of items:
1212
* Drop implementations of types without an explicit `Drop` implementation
1313

1414
The lowering is triggered by calling the [`mir_built`] query.
15-
The MIR builder does
16-
not actually use the HIR but operates on the [THIR] instead, processing THIR
17-
expressions recursively.
15+
The MIR builder does not actually use the HIR,
16+
but operates on the [THIR] instead,
17+
processing THIR expressions recursively.
1818

1919
The lowering creates local variables for every argument as specified in the signature.
2020
Next, it creates local variables for every binding specified (e.g. `(a, b): (i32, String)`)
2121
produces 3 bindings, one for the argument, and two for the bindings.
22-
Next, it generates
23-
field accesses that read the fields from the argument and writes the value to the binding
24-
variable.
22+
Next,
23+
it generates field accesses that read the fields from the argument,
24+
and writes the value to the binding variable.
2525

2626
With this initialization out of the way, the lowering triggers a recursive call
2727
to a function that generates the MIR for the body (a `Block` expression) and
@@ -93,10 +93,9 @@ representations:
9393
We start out with lowering the function body to an `Rvalue` so we can create an
9494
assignment to `RETURN_PLACE`, This `Rvalue` lowering will in turn trigger lowering to
9595
`Operand` for its arguments (if any).
96-
`Operand` lowering either produces a `const`
97-
operand, or moves/copies out of a `Place`, thus triggering a `Place` lowering.
98-
An
99-
expression being lowered to a `Place` can in turn trigger a temporary to be created
96+
`Operand` lowering either produces a `const` operand,
97+
or moves/copies out of a `Place`, thus triggering a `Place` lowering.
98+
An expression being lowered to a `Place` can in turn trigger a temporary to be created
10099
if the expression being lowered contains operations.
101100
This is where the snake bites its
102101
own tail and we need to trigger an `Rvalue` lowering for the expression to be written

0 commit comments

Comments
 (0)