From 77aeb7b6f1c9ac0f019ccced357d5f5ff7af40c8 Mon Sep 17 00:00:00 2001 From: James Alan Preiss Date: Sat, 11 Jun 2016 20:31:01 -0700 Subject: [PATCH 1/2] fix typo in primitive-types section on slices --- src/doc/book/primitive-types.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/doc/book/primitive-types.md b/src/doc/book/primitive-types.md index b6a123bb3674c..ea0bdf29fcc41 100644 --- a/src/doc/book/primitive-types.md +++ b/src/doc/book/primitive-types.md @@ -163,7 +163,7 @@ A ‘slice’ is a reference to (or “view” into) another data structure. The useful for allowing safe, efficient access to a portion of an array without copying. For example, you might want to reference only one line of a file read into memory. By nature, a slice is not created directly, but from an existing -variable binding. Slices have a defined length, can be mutable or immutable. +variable binding. Slices have a defined length, and can be mutable or immutable. Internally, slices are represented as a pointer to the beginning of the data and a length. From c0c43b1e27411fb6fd1df4b8fe44f153f988c8bc Mon Sep 17 00:00:00 2001 From: James Alan Preiss Date: Sat, 11 Jun 2016 20:46:23 -0700 Subject: [PATCH 2/2] typo fix in loops.md --- src/doc/book/loops.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/doc/book/loops.md b/src/doc/book/loops.md index 97ca2e3e702f6..e23e6f3a786a5 100644 --- a/src/doc/book/loops.md +++ b/src/doc/book/loops.md @@ -178,7 +178,7 @@ loop { We now loop forever with `loop` and use `break` to break out early. Issuing an explicit `return` statement will also serve to terminate the loop early. -`continue` is similar, but instead of ending the loop, goes to the next +`continue` is similar, but instead of ending the loop, it goes to the next iteration. This will only print the odd numbers: ```rust