mirror of
https://github.com/servo/servo.git
synced 2025-08-03 20:50:07 +01:00
tidy: Fix rustdoc warnings and add a tidy check for a common URL issue (#33366)
This change fixes all rustdoc errors and also adds a tidy check for a very common rustdoc URL issue. Eventually rustdoc warnings should likely cause the build to fail, but this catches those issues sooner in order to not waste so much developer time. Signed-off-by: Martin Robinson <mrobinson@igalia.com>
This commit is contained in:
parent
f6ae050077
commit
e70507ca40
19 changed files with 107 additions and 36 deletions
|
@ -140,7 +140,7 @@ pub(crate) struct DisplayListBuilder<'a> {
|
|||
/// list building functions.
|
||||
current_scroll_node_id: ScrollTreeNodeId,
|
||||
|
||||
/// The current [ScrollNodeTreeId] for this [DisplayListBuilder]. This is necessary in addition
|
||||
/// The current [ScrollTreeNodeId] for this [DisplayListBuilder]. This is necessary in addition
|
||||
/// to the [Self::current_scroll_node_id], because some pieces of fragments as backgrounds with
|
||||
/// `background-attachment: fixed` need to not scroll while the rest of the fragment does.
|
||||
current_reference_frame_scroll_node_id: ScrollTreeNodeId,
|
||||
|
|
|
@ -24,11 +24,11 @@ pub(crate) struct InlineBox {
|
|||
pub base_fragment_info: BaseFragmentInfo,
|
||||
#[serde(skip_serializing)]
|
||||
pub style: Arc<ComputedValues>,
|
||||
/// The identifier of this inline box in the containing [`InlineFormattingContext`].
|
||||
/// The identifier of this inline box in the containing [`super::InlineFormattingContext`].
|
||||
pub(super) identifier: InlineBoxIdentifier,
|
||||
pub is_first_fragment: bool,
|
||||
pub is_last_fragment: bool,
|
||||
/// The index of the default font in the [`InlineFormattingContext`]'s font metrics store.
|
||||
/// The index of the default font in the [`super::InlineFormattingContext`]'s font metrics store.
|
||||
/// This is initialized during IFC shaping.
|
||||
pub default_font_index: Option<usize>,
|
||||
}
|
||||
|
@ -58,12 +58,12 @@ impl InlineBox {
|
|||
|
||||
#[derive(Debug, Default, Serialize)]
|
||||
pub(crate) struct InlineBoxes {
|
||||
/// A collection of all inline boxes in a particular [`InlineFormattingContext`].
|
||||
/// A collection of all inline boxes in a particular [`super::InlineFormattingContext`].
|
||||
inline_boxes: Vec<ArcRefCell<InlineBox>>,
|
||||
|
||||
/// A list of tokens that represent the actual tree of inline boxes, while allowing
|
||||
/// easy traversal forward and backwards through the tree. This structure is also
|
||||
/// stored in the [`InlineFormattingContext::inline_items`], but this version is
|
||||
/// stored in the [`super::InlineFormattingContext::inline_items`], but this version is
|
||||
/// faster to iterate.
|
||||
inline_box_tree: Vec<InlineBoxTreePathToken>,
|
||||
}
|
||||
|
@ -182,7 +182,7 @@ pub(crate) struct InlineBoxIdentifier {
|
|||
|
||||
pub(super) struct InlineBoxContainerState {
|
||||
/// The container state common to both [`InlineBox`] and the root of the
|
||||
/// [`InlineFormattingContext`].
|
||||
/// [`super::InlineFormattingContext`].
|
||||
pub base: InlineContainerState,
|
||||
|
||||
/// The [`InlineBoxIdentifier`] of this inline container state. If this is the root
|
||||
|
|
|
@ -130,11 +130,11 @@ pub(super) struct LineItemLayout<'layout_data, 'layout> {
|
|||
/// The state of the overall [`super::InlineFormattingContext`] layout.
|
||||
layout: &'layout mut InlineFormattingContextLayout<'layout_data>,
|
||||
|
||||
/// The set of [`super::LineItemLayoutInlineContainerState`] created while laying out items
|
||||
/// The set of [`LineItemLayoutInlineContainerState`] created while laying out items
|
||||
/// on this line. This does not include the current level of recursion.
|
||||
pub state_stack: Vec<LineItemLayoutInlineContainerState>,
|
||||
|
||||
/// The current [`super::LineItemLayoutInlineContainerState`].
|
||||
/// The current [`LineItemLayoutInlineContainerState`].
|
||||
pub current_state: LineItemLayoutInlineContainerState,
|
||||
|
||||
/// The metrics of this line, which should remain constant throughout the
|
||||
|
|
|
@ -737,9 +737,8 @@ impl<'layout_dta> InlineFormattingContextLayout<'layout_dta> {
|
|||
self.inline_box_state_stack.push(inline_box_state);
|
||||
}
|
||||
|
||||
/// Finish laying out a particular [`InlineBox`] into line items. This will add the
|
||||
/// final [`InlineBoxLineItem`] to the state and pop its state off of
|
||||
/// [`Self::inline_box_state_stack`].
|
||||
/// Finish laying out a particular [`InlineBox`] into line items. This will
|
||||
/// pop its state off of [`Self::inline_box_state_stack`].
|
||||
fn finish_inline_box(&mut self) {
|
||||
let inline_box_state = match self.inline_box_state_stack.pop() {
|
||||
Some(inline_box_state) => inline_box_state,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue