Merge pull request #304 from florolf/fix-ch06-typos

fix some typos in chapter 6
This commit is contained in:
Carol (Nichols || Goulding)
2016-10-18 09:55:11 -04:00
committed by GitHub
2 changed files with 2 additions and 2 deletions
+1 -1
View File
@@ -84,7 +84,7 @@ suggestions in a totally different direction! /Carol -->
An `enum` definition is similar to a `struct` definition: it defines a new type
and a template of what instances of that new type will be like. When you want to
use a struct, you create an instance of the struct. When you want to use an
enum, you use an instannce of the enum that is one of the variants the enum
enum, you use an instance of the enum that is one of the variants the enum
allows.
<!-- Option 2: -->
+1 -1
View File
@@ -1,6 +1,6 @@
## The `Option` Enum and its Advantages Over Null Values
In the previous section, we looked at how the `IpAddr` enum let us use Rust's
In the previous section, we looked at how the `IpAddr` enum lets us use Rust's
type system to encode more information than just the data into our program.
This section is a case study of `Option`, which is another enum defined by the
standard library. The `Option` type is used in many places because it encodes