From 2df8830642fffa6c68aa6318985cfcd2e63db81b Mon Sep 17 00:00:00 2001 From: Tom Jakubowski Date: Mon, 23 Mar 2015 14:01:28 -0700 Subject: rustdoc: Support for "array" primitive Impls on `clean::Type::FixedVector` are now collected in the array primitive page instead of the slice primitive page. Also add a primitive docs for arrays to `std`. --- src/libstd/array.rs | 13 +++++++++++++ src/libstd/lib.rs | 6 +++++- 2 files changed, 18 insertions(+), 1 deletion(-) create mode 100644 src/libstd/array.rs (limited to 'src/libstd') diff --git a/src/libstd/array.rs b/src/libstd/array.rs new file mode 100644 index 00000000000..a6b8cd71a3b --- /dev/null +++ b/src/libstd/array.rs @@ -0,0 +1,13 @@ +// Copyright 2015 The Rust Project Developers. See the COPYRIGHT +// file at the top-level directory of this distribution and at +// http://rust-lang.org/COPYRIGHT. +// +// Licensed under the Apache License, Version 2.0 or the MIT license +// , at your +// option. This file may not be copied, modified, or distributed +// except according to those terms. + +//! The fixed-size array type (`[T; n]`). + +#![doc(primitive = "array")] diff --git a/src/libstd/lib.rs b/src/libstd/lib.rs index b055796ba54..5839e3fb638 100644 --- a/src/libstd/lib.rs +++ b/src/libstd/lib.rs @@ -212,6 +212,9 @@ pub mod prelude; /* Primitive types */ +// NB: slice and str are primitive types too, but their module docs + primitive doc pages +// are inlined from the public re-exports of core_collections::{slice, str} above. + #[path = "num/float_macros.rs"] #[macro_use] mod float_macros; @@ -285,8 +288,9 @@ pub mod sync; pub mod rt; mod panicking; -// Documentation for primitive types +// Modules that exist purely to document + host impl docs for primitive types +mod array; mod bool; mod unit; mod tuple; -- cgit 1.4.1-3-g733a5