Skip to content

Commit 1c90a73

Browse files
committed
---
yaml --- r: 128189 b: refs/heads/try c: 0edc55d h: refs/heads/master i: 128187: dbac738 v: v3
1 parent 46953c3 commit 1c90a73

File tree

3 files changed

+3
-9
lines changed

3 files changed

+3
-9
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
refs/heads/master: cb9c1e0e702f4a1a5dfc909b15b74e8556013c06
33
refs/heads/snap-stage1: e33de59e47c5076a89eadeb38f4934f58a3618a6
44
refs/heads/snap-stage3: aa98b25c4f0c10729dff37c699904ad57b8fbda8
5-
refs/heads/try: d9177707926d4fbed9dd9e4e7afc9a8c185dafe0
5+
refs/heads/try: 0edc55dc21089ba50e5dc49b3aa5f894b7675f3b
66
refs/tags/release-0.1: 1f5c5126e96c79d22cb7862f75304136e204f105
77
refs/heads/ndm: f3868061cd7988080c30d6d5bf352a5a5fe2460b
88
refs/heads/try2: 147ecfdd8221e4a4d4e090486829a06da1e0ca3c

branches/try/src/doc/guide.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -666,7 +666,7 @@ This is not the same as this, which won't compile:
666666
```{ignore}
667667
let x = 5i;
668668
669-
let y: int = if x == 5 { 10i; } else { 15i; };
669+
let y: int = if x == 5i { 10i; } else { 15i; };
670670
```
671671

672672
Note the semicolons after the 10 and 15. Rust will give us the following error:

branches/try/src/doc/rust.md

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1356,9 +1356,6 @@ A *static item* is a named _constant value_ stored in the global data section of
13561356
Immutable static items are stored in the read-only data section.
13571357
The constant value bound to a static item is, like all constant values, evaluated at compile time.
13581358
Static items have the `static` lifetime, which outlives all other lifetimes in a Rust program.
1359-
Only values stored in the global data section (such as string constants
1360-
and static items) can have the `static` lifetime;
1361-
dynamically constructed values cannot safely be assigned the `static` lifetime.
13621359
Static items are declared with the `static` keyword.
13631360
A static item must have a _constant expression_ giving its definition.
13641361

@@ -3624,10 +3621,7 @@ There are four varieties of pointer in Rust:
36243621
References arise by (automatic) conversion from owning pointers, managed pointers,
36253622
or by applying the borrowing operator `&` to some other value,
36263623
including [lvalues, rvalues or temporaries](#lvalues,-rvalues-and-temporaries).
3627-
A borrow expression is written `&content`.
3628-
3629-
A reference type is written `&'f type` for some lifetime-variable `f`,
3630-
or just `&type` when the lifetime can be elided;
3624+
References are written `&content`, or in some cases `&'f content` for some lifetime-variable `f`,
36313625
for example `&int` means a reference to an integer.
36323626
Copying a reference is a "shallow" operation:
36333627
it involves only copying the pointer itself.

0 commit comments

Comments
 (0)