Skip to content

Commit

Permalink
Rollup merge of #129793 - lolbinarycat:doc-missing-newlines, r=workin…
Browse files Browse the repository at this point in the history
…gjubilee

add extra linebreaks so rustdoc can identify the first sentence

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
matthiaskrgr authored Sep 2, 2024
2 parents dce2665 + 0064bd1 commit 8c28989
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 8c28989

Please sign in to comment.