about summary refs log tree commit diff
diff options
context:
space:
mode:
authorManish Goregaokar <manishsmail@gmail.com>2015-04-17 18:16:12 +0530
committerManish Goregaokar <manishsmail@gmail.com>2015-04-17 19:01:32 +0530
commit1b6bd92790c4021ca83ff63f96767468f37f8ce3 (patch)
treeb486131b0b8b33d094caf2f735ef0b9ef676c1df
parent27dc069234c560b64c5651d086af3f7af5dfc533 (diff)
parentd9515ad40fe24feea4da0a740d9e0cfe0aa3814e (diff)
downloadrust-1b6bd92790c4021ca83ff63f96767468f37f8ce3.tar.gz
rust-1b6bd92790c4021ca83ff63f96767468f37f8ce3.zip
Rollup merge of #24515 - steveklabnik:gh24070, r=Gankro
 Fixes #24070

or rather, fixes it even though it's already been fixed: slices are before now. But the linking is nice anyway.
-rw-r--r--src/doc/trpl/vectors.md9
1 files changed, 7 insertions, 2 deletions
diff --git a/src/doc/trpl/vectors.md b/src/doc/trpl/vectors.md
index 0dfbfc11913..6fa5917ea99 100644
--- a/src/doc/trpl/vectors.md
+++ b/src/doc/trpl/vectors.md
@@ -1,13 +1,18 @@
 % Vectors
 
 A *vector* is a dynamic or "growable" array, implemented as the standard
-library type [`Vec<T>`](../std/vec/) (Where `<T>` is a [Generic](./generics.md) statement). 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:
+library type [`Vec<T>`](../std/vec/) (Where `<T>` is a [Generic](./generics.md)
+statement). Vectors always allocate their data on the heap. Vectors are to
+[slices][slices] what [`String`][string] is to `&str`. You can
+create them with the `vec!` macro:
 
 ```{rust}
 let v = vec![1, 2, 3]; // v: Vec<i32>
 ```
 
+[slices]: primitive-types.html#slices
+[string]: strings.html
+
 (Notice that unlike the `println!` macro we've used in the past, we use square
 brackets `[]` with `vec!`. Rust allows you to use either in either situation,
 this is just convention.)