Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

docs: fix warnings and use warning note #266

Closed
wants to merge 1 commit into from

Conversation

marxin
Copy link
Contributor

@marxin marxin commented Jun 7, 2024

Fixes:

warning: redundant explicit link target
   --> binrw/src/../doc/attribute.md:120:85
    |
120 | | rw  | [`try_calc`](#calculations) | field | Like `calc`, but
returns a [`Result`](Result).
    |
--------  ^^^^^^ explicit target is redundant
    |
|
    |
because label contains path that resolves to same destination
    |
    = note: when a link's destination is not specified,
            the label is used to resolve intra-doc links
    = note: `#[warn(rustdoc::redundant_explicit_links)]` on by default
help: remove explicit link target
    |
120 | | rw  | [`try_calc`](#calculations) | field | Like `calc`, but
returns a [`Result`].
    |
~~~~~~~~~~

warning: redundant explicit link target
   --> binrw/src/../doc/attribute.md:121:92
    |
121 | | rw  | [`try_map`](#map) | all except unit variant | Like `map`,
but returns a [`Result`](Result).
    |
--------  ^^^^^^ explicit target is redundant
    |
|
    |
because label contains path that resolves to same destination
    |
    = note: when a link's destination is not specified,
            the label is used to resolve intra-doc links
help: remove explicit link target
    |
121 | | rw  | [`try_map`](#map) | all except unit variant | Like `map`,
but returns a [`Result`].
    |
~~~~~~~~~~

warning: redundant explicit link target
    --> binrw/src/../doc/attribute.md:1520:13
     |
1520 | [`Default`](core::default::Default) instead of reading data from
the reader:
     |  ---------  ^^^^^^^^^^^^^^^^^^^^^^ explicit target is redundant
     |  |
     |  because label contains path that resolves to same destination
     |
     = note: when a link's destination is not specified,
             the label is used to resolve intra-doc links
help: remove explicit link target
     |
1520 | [`Default`] instead of reading data from the reader:
     | ~~~~~~~~~~~

warning: `binrw` (lib doc) generated 3 warnings

Fixes:
```
warning: redundant explicit link target
   --> binrw/src/../doc/attribute.md:120:85
    |
120 | | rw  | [`try_calc`](#calculations) | field | Like `calc`, but
returns a [`Result`](Result).
    |
--------  ^^^^^^ explicit target is redundant
    |
|
    |
because label contains path that resolves to same destination
    |
    = note: when a link's destination is not specified,
            the label is used to resolve intra-doc links
    = note: `#[warn(rustdoc::redundant_explicit_links)]` on by default
help: remove explicit link target
    |
120 | | rw  | [`try_calc`](#calculations) | field | Like `calc`, but
returns a [`Result`].
    |
~~~~~~~~~~

warning: redundant explicit link target
   --> binrw/src/../doc/attribute.md:121:92
    |
121 | | rw  | [`try_map`](#map) | all except unit variant | Like `map`,
but returns a [`Result`](Result).
    |
--------  ^^^^^^ explicit target is redundant
    |
|
    |
because label contains path that resolves to same destination
    |
    = note: when a link's destination is not specified,
            the label is used to resolve intra-doc links
help: remove explicit link target
    |
121 | | rw  | [`try_map`](#map) | all except unit variant | Like `map`,
but returns a [`Result`].
    |
~~~~~~~~~~

warning: redundant explicit link target
    --> binrw/src/../doc/attribute.md:1520:13
     |
1520 | [`Default`](core::default::Default) instead of reading data from
the reader:
     |  ---------  ^^^^^^^^^^^^^^^^^^^^^^ explicit target is redundant
     |  |
     |  because label contains path that resolves to same destination
     |
     = note: when a link's destination is not specified,
             the label is used to resolve intra-doc links
help: remove explicit link target
     |
1520 | [`Default`] instead of reading data from the reader:
     | ~~~~~~~~~~~

warning: `binrw` (lib doc) generated 3 warnings
```
csnover pushed a commit to csnover/binrw that referenced this pull request Jul 5, 2024
@csnover csnover closed this in f607832 Jul 5, 2024
@marxin marxin deleted the docs-enhance branch July 6, 2024 14:23
csnover pushed a commit to csnover/binrw that referenced this pull request Oct 13, 2024
Closes jam1garner#266.

(cherry picked from commit f607832)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant