]> git.lizzy.rs Git - rust.git/commitdiff
Small tweaks for the documentation of the primitive type array
authorUlrik Sverdrup <bluss@users.noreply.github.com>
Fri, 10 Jul 2015 12:50:35 +0000 (14:50 +0200)
committerUlrik Sverdrup <bluss@users.noreply.github.com>
Fri, 10 Jul 2015 12:50:35 +0000 (14:50 +0200)
src/libstd/array.rs

index e79e5d5a680f60bc3a8b2284adeb59eef252c0a7..0dfcc72e3791025cef9ae217059cbf03d97918f2 100644 (file)
@@ -9,7 +9,7 @@
 // except according to those terms.
 
 //! A fixed-size array is denoted `[T; N]` for the element type `T` and
-//! the compile time constant size `N`. The size should be zero or positive.
+//! the compile time constant size `N`. The size must be zero or positive.
 //!
 //! Arrays values are created either with an explicit expression that lists
 //! each element: `[x, y, z]` or a repeat expression: `[x; N]`. The repeat
@@ -32,7 +32,9 @@
 //!
 //! [slice]: primitive.slice.html
 //!
-//! ## Examples
+//! Rust does not currently support generics over the size of an array type.
+//!
+//! # Examples
 //!
 //! ```
 //! let mut array: [i32; 3] = [0; 3];
@@ -49,7 +51,5 @@
 //!
 //! ```
 //!
-//! Rust does not currently support generics over the size of an array type.
-//!
 
 #![doc(primitive = "array")]