about summary refs log tree commit diff
diff options
context:
space:
mode:
authorMarc <marc.gluyas@gmail.com>2019-04-15 13:19:38 +1200
committerMarc <marc.gluyas@gmail.com>2019-04-15 20:30:52 +1200
commit64dc041511852441ebc071c6fdf1e110e80b7b97 (patch)
tree1a7664d7eb7558dec34b3fdfcaf6594cd515b0d2
parentaa99abeb262307d5e9aa11a792312fd620b7f89a (diff)
downloadrust-64dc041511852441ebc071c6fdf1e110e80b7b97.tar.gz
rust-64dc041511852441ebc071c6fdf1e110e80b7b97.zip
Remove collection-specific `with_capacity` doc from `std::collections`
Fixes #59931
-rw-r--r--src/libstd/collections/mod.rs7
1 files changed, 3 insertions, 4 deletions
diff --git a/src/libstd/collections/mod.rs b/src/libstd/collections/mod.rs
index 286ce2d389b..15c2532f8b4 100644
--- a/src/libstd/collections/mod.rs
+++ b/src/libstd/collections/mod.rs
@@ -150,10 +150,9 @@
 //! Any `with_capacity` constructor will instruct the collection to allocate
 //! enough space for the specified number of elements. Ideally this will be for
 //! exactly that many elements, but some implementation details may prevent
-//! this. [`Vec`] and [`VecDeque`] can be relied on to allocate exactly the
-//! requested amount, though. Use `with_capacity` when you know exactly how many
-//! elements will be inserted, or at least have a reasonable upper-bound on that
-//! number.
+//! this. See collection-specific documentation for details. In general, use
+//! `with_capacity` when you know exactly how many elements will be inserted, or
+//! at least have a reasonable upper-bound on that number.
 //!
 //! When anticipating a large influx of elements, the `reserve` family of
 //! methods can be used to hint to the collection how much room it should make