Skip to content

Commit 86ecfa4

Browse files
committed
auto merge of #16476 : andreastt/rust/ato/consistency_if_expr_example, r=steveklabnik
2 parents d917770 + 0edc55d commit 86ecfa4

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/doc/guide.md

+1-1
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:

0 commit comments

Comments
 (0)