From 6d2e3d4bc05cb53fc6d6424293af93fecb495b4b Mon Sep 17 00:00:00 2001 From: Steve Klabnik Date: Fri, 13 Feb 2015 17:52:46 -0500 Subject: [PATCH] Note that Vec is heap allocated. Fixes #20948 --- src/doc/trpl/arrays-vectors-and-slices.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/doc/trpl/arrays-vectors-and-slices.md b/src/doc/trpl/arrays-vectors-and-slices.md index 2df769b3c2c..d4e2ad5cd5f 100644 --- a/src/doc/trpl/arrays-vectors-and-slices.md +++ b/src/doc/trpl/arrays-vectors-and-slices.md @@ -49,8 +49,8 @@ languages. A *vector* is a dynamic or "growable" array, implemented as the standard library type [`Vec`](../std/vec/) (we'll talk about what the `` means -later). Vectors are to arrays what `String` is to `&str`. You can create them -with the `vec!` macro: +later). Vectors always allocate their data on the heap. Vectors are to slices +what `String` is to `&str`. You can create them with the `vec!` macro: ```{rust} let v = vec![1, 2, 3]; // v: Vec