Skip to content

Commit ba6c808

Browse files
committed
Rollup merge of rust-lang#26936 - bluss:doc-array, r=steveklabnik
Small tweaks for the documentation of the primitive type array Follow up to PR rust-lang#26923, fix a few small details.
2 parents bb73c7a + da03fc6 commit ba6c808

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

src/libstd/array.rs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
// except according to those terms.
1010

1111
//! A fixed-size array is denoted `[T; N]` for the element type `T` and
12-
//! the compile time constant size `N`. The size should be zero or positive.
12+
//! the compile time constant size `N`. The size must be zero or positive.
1313
//!
1414
//! Arrays values are created either with an explicit expression that lists
1515
//! each element: `[x, y, z]` or a repeat expression: `[x; N]`. The repeat
@@ -32,7 +32,9 @@
3232
//!
3333
//! [slice]: primitive.slice.html
3434
//!
35-
//! ## Examples
35+
//! Rust does not currently support generics over the size of an array type.
36+
//!
37+
//! # Examples
3638
//!
3739
//! ```
3840
//! let mut array: [i32; 3] = [0; 3];
@@ -49,7 +51,5 @@
4951
//!
5052
//! ```
5153
//!
52-
//! Rust does not currently support generics over the size of an array type.
53-
//!
5454
5555
#![doc(primitive = "array")]

0 commit comments

Comments
 (0)