about summary refs log tree commit diff
diff options
context:
space:
mode:
authorDylan DPC <dylan.dpc@gmail.com>2020-04-23 20:35:06 +0200
committerGitHub <noreply@github.com>2020-04-23 20:35:06 +0200
commit5f9ffb9c0237314c267736bfe7dc12b91e18141f (patch)
treea94859656fef3e2254a412a9ef70b43755bde06b
parent199f4deef0ac8ccfe02a8290eadd0ab3ae66d71c (diff)
parent0ad9a4d26e1757d55a4c3dc81f3cad01ce7db12a (diff)
downloadrust-5f9ffb9c0237314c267736bfe7dc12b91e18141f.tar.gz
rust-5f9ffb9c0237314c267736bfe7dc12b91e18141f.zip
Rollup merge of #71470 - TyPR124:fix-doc-links, r=jonas-schievink
Fix doc links

This fixes a few doc links which were causing `cargo doc` to fail when using `--document-private-items --document-hidden-items` on libstd. Most of the fixes are just escaping '[' and ']' characters in doc comments, and one change actually fixes a doc link.
-rw-r--r--src/liballoc/collections/vec_deque.rs2
-rw-r--r--src/liballoc/rc.rs2
-rw-r--r--src/liballoc/sync.rs2
-rw-r--r--src/libcore/ffi.rs2
4 files changed, 4 insertions, 4 deletions
diff --git a/src/liballoc/collections/vec_deque.rs b/src/liballoc/collections/vec_deque.rs
index a3b61f1f4a5..2f50234b6d5 100644
--- a/src/liballoc/collections/vec_deque.rs
+++ b/src/liballoc/collections/vec_deque.rs
@@ -73,7 +73,7 @@ pub struct VecDeque<T> {
 /// It produces the following sequence of matching slices:
 ///
 /// ([0 1], [a b])
-/// ([2], [c])
+/// (\[2\], \[c\])
 /// ([3 4], [d e])
 ///
 /// and the uneven remainder of either A or B is skipped.
diff --git a/src/liballoc/rc.rs b/src/liballoc/rc.rs
index e106b4354e4..fb9f5faa018 100644
--- a/src/liballoc/rc.rs
+++ b/src/liballoc/rc.rs
@@ -1024,7 +1024,7 @@ unsafe fn set_data_ptr<T: ?Sized, U>(mut ptr: *mut T, data: *mut U) -> *mut T {
 }
 
 impl<T> Rc<[T]> {
-    /// Copy elements from slice into newly allocated Rc<[T]>
+    /// Copy elements from slice into newly allocated Rc<\[T\]>
     ///
     /// Unsafe because the caller must either take ownership or bind `T: Copy`
     unsafe fn copy_from_slice(v: &[T]) -> Rc<[T]> {
diff --git a/src/liballoc/sync.rs b/src/liballoc/sync.rs
index 54df2b60857..cde412bee78 100644
--- a/src/liballoc/sync.rs
+++ b/src/liballoc/sync.rs
@@ -902,7 +902,7 @@ unsafe fn set_data_ptr<T: ?Sized, U>(mut ptr: *mut T, data: *mut U) -> *mut T {
 }
 
 impl<T> Arc<[T]> {
-    /// Copy elements from slice into newly allocated Arc<[T]>
+    /// Copy elements from slice into newly allocated Arc<\[T\]>
     ///
     /// Unsafe because the caller must either take ownership or bind `T: Copy`.
     unsafe fn copy_from_slice(v: &[T]) -> Arc<[T]> {
diff --git a/src/libcore/ffi.rs b/src/libcore/ffi.rs
index 6277da4f123..7bc2866dc2e 100644
--- a/src/libcore/ffi.rs
+++ b/src/libcore/ffi.rs
@@ -282,7 +282,7 @@ impl<'a, 'f: 'a> DerefMut for VaList<'a, 'f> {
 mod sealed_trait {
     /// Trait which whitelists the allowed types to be used with [VaList::arg]
     ///
-    /// [VaList::va_arg]: struct.VaList.html#method.arg
+    /// [VaList::arg]: ../struct.VaList.html#method.arg
     #[unstable(
         feature = "c_variadic",
         reason = "the `c_variadic` feature has not been properly tested on \