Skip to content

Commit

Permalink
add extra linebreaks so rustdoc can identify the first sentence
Browse files Browse the repository at this point in the history
there should probably be a lint against this in rustdoc, it causes
too many lines to be shown in the short documentation overviews

expecially noticable for the slice primative type:
https://doc.rust-lang.org/std/index.html
  • Loading branch information
lolbinarycat authored and workingjubilee committed Sep 1, 2024
1 parent 6cf068d commit 0064bd1
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
1 change: 1 addition & 0 deletions library/core/src/hint.rs
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
#![stable(feature = "core_hint", since = "1.27.0")]

//! Hints to compiler that affects how code should be emitted or optimized.
//!
//! Hints may be compile time or runtime.

use crate::{intrinsics, ub_checks};
Expand Down
5 changes: 3 additions & 2 deletions library/core/src/primitive_docs.rs
Original file line number Diff line number Diff line change
Expand Up @@ -832,8 +832,9 @@ mod prim_array {}
#[doc(alias = "[")]
#[doc(alias = "]")]
#[doc(alias = "[]")]
/// A dynamically-sized view into a contiguous sequence, `[T]`. Contiguous here
/// means that elements are laid out so that every element is the same
/// A dynamically-sized view into a contiguous sequence, `[T]`.
///
/// Contiguous here means that elements are laid out so that every element is the same
/// distance from its neighbors.
///
/// *[See also the `std::slice` module](crate::slice).*
Expand Down

0 comments on commit 0064bd1

Please sign in to comment.