about summary refs log tree commit diff
diff options
context:
space:
mode:
authorBrian Anderson <banderson@mozilla.com>2012-10-06 22:35:08 -0700
committerBrian Anderson <banderson@mozilla.com>2012-10-06 22:35:08 -0700
commitba26dc50cecb66e10e183dc834fb570979a475b7 (patch)
treecae8ff6d4b603c281b5a587171b0d0aa0c9b37e9
parent0b2ffa5692ce83bbf499262e6023c8f7673f0522 (diff)
docs: Remove more uses of records
-rw-r--r--doc/tutorial.md6
1 files changed, 3 insertions, 3 deletions
diff --git a/doc/tutorial.md b/doc/tutorial.md
index 0badbb8c05d..78a7b5e5f25 100644
--- a/doc/tutorial.md
+++ b/doc/tutorial.md
@@ -859,12 +859,12 @@ get at their contents. All variant constructors can be used as
 patterns, as in this definition of `area`:
 
 ~~~~
-# type Point = {x: float, y: float};
+# struct Point {x: float, y: float}
 # enum Shape { Circle(Point, float), Rectangle(Point, Point) }
 fn area(sh: Shape) -> float {
     match sh {
         Circle(_, size) => float::consts::pi * size * size,
-        Rectangle({x, y}, {x: x2, y: y2}) => (x2 - x) * (y2 - y)
+        Rectangle(Point {x, y}, Point {x: x2, y: y2}) => (x2 - x) * (y2 - y)
     }
 }
 ~~~~
@@ -875,7 +875,7 @@ their introductory form, nullary enum patterns are written without
 parentheses.
 
 ~~~~
-# type Point = {x: float, y: float};
+# struct Point {x: float, y: float}
 # enum Direction { North, East, South, West }
 fn point_from_direction(dir: Direction) -> Point {
     match dir {