Docs: rustdoc builds the formats and loader crates without warnings #272

Closed
SkippySteve wants to merge 1 commit from upstream-pr/272 into main
SkippySteve commented 2026-11-24 01:58:20 +00:00 (Migrated from github.com)

Imported from Marvisak/VIctory. Originally posted by SkippySteve on 2026-11-24T01:58:20Z.


cargo doc --no-deps warns twice on main, in crates that document on any host:

warning: public documentation for `texture` links to private item `MICRO`
  --> crates/victory-formats/src/texture.rs:16:19
warning: `prepare` is both a function and a module
 --> crates/victory-loader/src/lib.rs:7:10
  • texture.rs: MICRO is a private table, so the public module page can't link to it. It stays in code font, without the link.
  • loader lib.rs: step 1 of the overview refers to the function, so the link is now [`prepare()`]. rustdoc resolves it to the function and no longer has to choose between the function and the prepare module.

The change is two comment lines. No code changes.

Testing (Linux)

  • RUSTDOCFLAGS="-D warnings" cargo doc --no-deps -p victory-core -p victory-pe -p victory-loader -p victory-formats -p victory-pipeline -p victory-game -p victory-shader passes. On main it fails on the two warnings above.
  • cargo clippy -p victory-formats -p victory-loader --all-targets -- -D warnings is clean.
  • cargo test -p victory-formats: 20 passed, 3 ignored.
  • cargo test -p victory-loader: the three prepare::tests that parse the test's own binary fail on Linux, both here and on main ("Unknown file magic", because that binary is ELF). This PR doesn't touch them.
<!-- greyfinch-sync:Marvisak/VIctory:issue:6572865394 --> Imported from [Marvisak/VIctory](https://github.com/Marvisak/VIctory/pull/272). Originally posted by [SkippySteve](https://github.com/SkippySteve) on 2026-11-24T01:58:20Z. --- `cargo doc --no-deps` warns twice on main, in crates that document on any host: ``` warning: public documentation for `texture` links to private item `MICRO` --> crates/victory-formats/src/texture.rs:16:19 warning: `prepare` is both a function and a module --> crates/victory-loader/src/lib.rs:7:10 ``` - **texture.rs:** `MICRO` is a private table, so the public module page can't link to it. It stays in code font, without the link. - **loader lib.rs:** step 1 of the overview refers to the function, so the link is now `` [`prepare()`] ``. rustdoc resolves it to the function and no longer has to choose between the function and the `prepare` module. The change is two comment lines. No code changes. ### Testing (Linux) - `RUSTDOCFLAGS="-D warnings" cargo doc --no-deps -p victory-core -p victory-pe -p victory-loader -p victory-formats -p victory-pipeline -p victory-game -p victory-shader` passes. On main it fails on the two warnings above. - `cargo clippy -p victory-formats -p victory-loader --all-targets -- -D warnings` is clean. - `cargo test -p victory-formats`: 20 passed, 3 ignored. - `cargo test -p victory-loader`: the three `prepare::tests` that parse the test's own binary fail on Linux, both here and on main ("Unknown file magic", because that binary is ELF). This PR doesn't touch them.
upstream-sync closed this pull request 2026-11-24 06:52:09 +00:00
SkippySteve commented 2026-11-24 06:55:10 +00:00 (Migrated from github.com)

Imported from Marvisak/VIctory. Originally posted by SkippySteve on 2026-11-24T02:27:55Z.


Superseded by #315, which now includes this rustdoc fix (same texture.rs).

<!-- greyfinch-sync:Marvisak/VIctory:comment:7120170171 --> Imported from [Marvisak/VIctory](https://github.com/Marvisak/VIctory/pull/272#issuecomment-7120170171). Originally posted by [SkippySteve](https://github.com/SkippySteve) on 2026-11-24T02:27:55Z. --- Superseded by #315, which now includes this rustdoc fix (same `texture.rs`).

Pull request closed

Sign in to join this conversation.
No reviewers
No labels
No milestone
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Reference
Marvisak/VIctory!272
No description provided.