Skip to content

Commit 8f34c15

Browse files
committed
Merge pull request #1576 from mbrubeck/master
More documentation fixes
2 parents ae83e56 + 2eda013 commit 8f34c15

File tree

1 file changed

+21
-3
lines changed

1 file changed

+21
-3
lines changed

doc/rust.md

Lines changed: 21 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1703,6 +1703,24 @@ as
17031703
= <- <->
17041704
~~~~
17051705

1706+
Operators at the same precedence level are evaluated left-to-right.
1707+
1708+
### Grouped expressions
1709+
1710+
An expression enclosed in parentheses evaluates to the result of the enclosed
1711+
expression. Parentheses can be used to explicitly specify evaluation order
1712+
within an expression.
1713+
1714+
~~~~~~~~{.ebnf .gram}
1715+
paren_expr : '(' expr ')' ;
1716+
~~~~~~~~
1717+
1718+
An example of a parenthesized expression:
1719+
1720+
~~~~
1721+
let x = (2 + 3) * 4;
1722+
~~~~
1723+
17061724
### Unary copy expressions
17071725

17081726
~~~~~~~~{.ebnf .gram}
@@ -2851,9 +2869,9 @@ and lifetime semantics of the memory model.
28512869

28522870
## Memory model
28532871

2854-
A Rust [task](#tasks)'s memory consists of a static set of *items*, a set of
2855-
tasks each with its own *stack*, and a *heap*. Immutable portions of the heap
2856-
may be shared between tasks, mutable portions may not.
2872+
A Rust program's memory consists of a static set of *items*, a set of
2873+
[tasks](#tasks) each with its own *stack*, and a *heap*. Immutable portions of
2874+
the heap may be shared between tasks, mutable portions may not.
28572875

28582876
Allocations in the stack consist of *slots*, and allocations in the heap
28592877
consist of *boxes*.

0 commit comments

Comments
 (0)