diff options
| author | Alex Crichton <alex@alexcrichton.com> | 2014-05-02 17:56:35 -0700 |
|---|---|---|
| committer | Alex Crichton <alex@alexcrichton.com> | 2014-05-03 17:36:20 -0700 |
| commit | 9306e840f59ac22651c6177a89352bf5d607fcbd (patch) | |
| tree | 0136e7a07c4110e04de87e962dc75ffea51a71dc /src/libstd | |
| parent | 9ac9245564356d4fbefc6d71276423079bf5307b (diff) | |
| download | rust-9306e840f59ac22651c6177a89352bf5d607fcbd.tar.gz rust-9306e840f59ac22651c6177a89352bf5d607fcbd.zip | |
rustdoc: Migrate from sundown to hoedown
This primary fix brought on by this upgrade is the proper matching of the ``` and ~~~ doc blocks. This also moves hoedown to a git submodule rather than a bundled repository. Additionally, hoedown is stricter about code blocks, so this ended up fixing a lot of invalid code blocks (ending with " ```" instead of "```", or ending with "~~~~" instead of "~~~"). Closes #12776
Diffstat (limited to 'src/libstd')
| -rw-r--r-- | src/libstd/c_str.rs | 2 | ||||
| -rw-r--r-- | src/libstd/iter.rs | 2 | ||||
| -rw-r--r-- | src/libstd/local_data.rs | 2 | ||||
| -rw-r--r-- | src/libstd/slice.rs | 8 | ||||
| -rw-r--r-- | src/libstd/str.rs | 2 |
5 files changed, 8 insertions, 8 deletions
diff --git a/src/libstd/c_str.rs b/src/libstd/c_str.rs index 310bc861cd3..7de74dbe507 100644 --- a/src/libstd/c_str.rs +++ b/src/libstd/c_str.rs @@ -61,7 +61,7 @@ fn main() { unsafe { puts(c_buffer); } }); } - ``` +``` */ diff --git a/src/libstd/iter.rs b/src/libstd/iter.rs index 18532c39443..62088e5b646 100644 --- a/src/libstd/iter.rs +++ b/src/libstd/iter.rs @@ -52,7 +52,7 @@ loop { None => { break } } } - ``` +``` This `for` loop syntax can be applied to any iterator over any type. diff --git a/src/libstd/local_data.rs b/src/libstd/local_data.rs index a6199aa43ab..072884a1f74 100644 --- a/src/libstd/local_data.rs +++ b/src/libstd/local_data.rs @@ -33,7 +33,7 @@ local_data::get(key_int, |opt| assert_eq!(opt.map(|x| *x), Some(3))); local_data::set(key_vector, ~[4]); local_data::get(key_vector, |opt| assert_eq!(*opt.unwrap(), ~[4])); - ``` +``` */ diff --git a/src/libstd/slice.rs b/src/libstd/slice.rs index 64f6b59be24..43159bcb44a 100644 --- a/src/libstd/slice.rs +++ b/src/libstd/slice.rs @@ -19,7 +19,7 @@ homogeneous types: ```rust let int_vector = [1,2,3]; let str_vector = ["one", "two", "three"]; - ``` +``` This is a big module, but for a high-level overview: @@ -44,7 +44,7 @@ a vector or a vector slice from the index interval `[a, b)`: let numbers = [0, 1, 2]; let last_numbers = numbers.slice(1, 3); // last_numbers is now &[1, 2] - ``` +``` Traits defined for the `~[T]` type, like `OwnedVector`, can only be called on such vectors. These methods deal with adding elements or otherwise changing @@ -57,7 +57,7 @@ of the vector: let mut numbers = vec![0, 1, 2]; numbers.push(7); // numbers is now vec![0, 1, 2, 7]; - ``` +``` ## Implementations of other traits @@ -79,7 +79,7 @@ let numbers = [0, 1, 2]; for &x in numbers.iter() { println!("{} is a number!", x); } - ``` +``` * `.mut_iter()` returns an iterator that allows modifying each value. * `.move_iter()` converts an owned vector into an iterator that diff --git a/src/libstd/str.rs b/src/libstd/str.rs index b105dd0ca5a..adb0c299876 100644 --- a/src/libstd/str.rs +++ b/src/libstd/str.rs @@ -37,7 +37,7 @@ fn main() { let borrowed_string1 = "This string is borrowed with the 'static lifetime"; let borrowed_string2: &str = owned_string; // owned strings can be borrowed } - ``` +``` From the example above, you can see that Rust has 2 different kinds of string literals. The owned literals correspond to the owned string types, but the |
