docs: fix broken links (#639)

Fixed a few broken links and converted a lot of them from the
html-link to intra-doc links.
This commit is contained in:
Gabriel Goller
2023-11-16 06:24:21 -05:00
committed by GitHub
parent bde8c50703
commit 72cbb92e0e
9 changed files with 9 additions and 25 deletions
+1 -3
View File
@@ -399,7 +399,7 @@ impl BytesMut {
///
/// Existing underlying capacity is preserved.
///
/// The [`split_off`] method can emulate `truncate`, but this causes the
/// The [split_off](`Self::split_off()`) method can emulate `truncate`, but this causes the
/// excess bytes to be returned instead of dropped.
///
/// # Examples
@@ -411,8 +411,6 @@ impl BytesMut {
/// buf.truncate(5);
/// assert_eq!(buf, b"hello"[..]);
/// ```
///
/// [`split_off`]: #method.split_off
pub fn truncate(&mut self, len: usize) {
if len <= self.len() {
unsafe {