Commit 0ab9043
Fix OSS rustdoc warnings breaking the Linux CI job
Summary:
The OSS `facebook/buck2` `linux-build-and-test` CI job has been red because `test.py`'s rustdoc stage runs `cargo doc --message-format=json --no-deps` and exits 1 on any documentation warning. Six warnings had accumulated. This fixes all four sites:
- `app/buck2_client_ctx/src/subscribers/superconsole.rs`: `rustdoc::invalid_html_tags` fired twice, reporting unclosed HTML tags "trace" and "argv", because the doc comment wrote the angle-bracketed placeholders as bare angle brackets, which rustdoc parses as HTML. Wrapped the phrase in backticks so it becomes inline code.
- `starlark-rust/starlark/src/values/types/enumeration.rs`: `rustdoc::broken_intra_doc_links` fired twice on a link to `EnumType`. No such public item exists — the module exports `pub(crate) use enum_type::AnyEnumType` and `pub use value::EnumValue`, and `enum_type.rs` declares only `pub(crate) struct EnumTypeGen`. Replaced the links with prose.
- `starlark-rust/starlark/src/values/alloc_value.rs`: `Heap::alloc_complex` does not exist; the real methods are `alloc_complex_no_freeze` and `alloc_complex_branded`. Pointed the link at `alloc_complex_no_freeze`.
- `starlark-rust/starlark/src/eval/runtime/params/spec.rs`: `rustdoc::private_intra_doc_links` fired because public documentation linked to `ParametersSpec::as_value`, which is `pub(crate) fn as_value`. Demoted the link to plain code formatting.
Note that `test.py` silently discards any rustdoc warning whose target `src_path` does not contain the substring `/buck2/`, so reproducing this locally requires checking the repo out into a path containing `/buck2/`.
Reviewed By: NavidQar
Differential Revision: D116114053
fbshipit-source-id: 4c9bda31589aca6fdb046d32889eca1a11a649111 parent 7eb1626 commit 0ab9043
3 files changed
Lines changed: 3 additions & 3 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
163 | 163 | | |
164 | 164 | | |
165 | 165 | | |
166 | | - | |
| 166 | + | |
167 | 167 | | |
168 | 168 | | |
169 | 169 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
35 | 35 | | |
36 | 36 | | |
37 | 37 | | |
38 | | - | |
| 38 | + | |
39 | 39 | | |
40 | 40 | | |
41 | 41 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
17 | 17 | | |
18 | 18 | | |
19 | 19 | | |
20 | | - | |
| 20 | + | |
21 | 21 | | |
22 | 22 | | |
23 | 23 | | |
| |||
0 commit comments