Skip to content

Added type-defs rather than just bools to aid with readability in librustdoc#153155

Closed
milosilo-dev wants to merge 1 commit intorust-lang:mainfrom
milosilo-dev:main
Closed

Added type-defs rather than just bools to aid with readability in librustdoc#153155
milosilo-dev wants to merge 1 commit intorust-lang:mainfrom
milosilo-dev:main

Conversation

@milosilo-dev
Copy link

This is my first pull request to rust so please tell me if I am doing anything wrong!

I have just implemented #87752

@rustbot rustbot added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-rustdoc Relevant to the rustdoc team, which will review and decide on the PR/issue. labels Feb 26, 2026
@rustbot
Copy link
Collaborator

rustbot commented Feb 26, 2026

r? @fmease

rustbot has assigned @fmease.
They will have a look at your PR within the next two weeks and either review your PR or reassign to another reviewer.

Use r? to explicitly pick a reviewer

Why was this reviewer chosen?

The reviewer was selected based on:

  • Owners of files modified in this PR: rustdoc
  • rustdoc expanded to 9 candidates
  • Random selection from GuillaumeGomez, fmease, lolbinarycat, notriddle

@rust-log-analyzer
Copy link
Collaborator

The job pr-check-2 failed! Check out the build log: (web) (plain enhanced) (plain)

Click to see the possible cause of the failure (guessed by this bot)
/dev/sda15      105M  6.2M   99M   6% /boot/efi
tmpfs           1.6G   12K  1.6G   1% /run/user/1001
================================================================================

Sufficient disk space available (95820224KB >= 52428800KB). Skipping cleanup.
##[group]Run echo "[CI_PR_NUMBER=$num]"
echo "[CI_PR_NUMBER=$num]"
shell: /usr/bin/bash --noprofile --norc -e -o pipefail {0}
---
   Compiling askama_macros v0.15.4
[RUSTC-TIMING] askama_macros test:false 0.142
    Checking askama v0.15.4
[RUSTC-TIMING] askama test:false 0.189
error[E0277]: the trait bound `ExternHTMLRootTakesPrecedence: std::clone::Clone` is not satisfied
   --> src/librustdoc/config.rs:272:5
    |
248 | #[derive(Clone, Debug)]
    |          ----- in this derive macro expansion
...
272 |     pub(crate) extern_html_root_takes_precedence: ExternHTMLRootTakesPrecedence,
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ the trait `std::clone::Clone` is not implemented for `ExternHTMLRootTakesPrecedence`
    |
   --> /rustc/9b1f8ff42d110b0ca138116745be921df5dc97e7/library/core/src/clone.rs:289:0
    |
    = note: in this expansion of `#[derive(Clone)]`
help: consider annotating `ExternHTMLRootTakesPrecedence` with `#[derive(Clone)]`
    |
240 + #[derive(Clone)]
241 | struct ExternHTMLRootTakesPrecedence(bool);
    |

error[E0277]: the trait bound `EnableIndexPage: std::clone::Clone` is not satisfied
   --> src/librustdoc/config.rs:280:5
    |
---
233 + #[derive(Clone)]
234 | struct EnableIndexPage(bool);
    |

error[E0277]: the trait bound `MarkdownNoToc: std::clone::Clone` is not satisfied
   --> src/librustdoc/config.rs:291:5
    |
248 | #[derive(Clone, Debug)]
    |          ----- in this derive macro expansion
...
291 |     pub(crate) markdown_no_toc: MarkdownNoToc,
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ the trait `std::clone::Clone` is not implemented for `MarkdownNoToc`
    |
   --> /rustc/9b1f8ff42d110b0ca138116745be921df5dc97e7/library/core/src/clone.rs:289:0
    |
    = note: in this expansion of `#[derive(Clone)]`
help: consider annotating `MarkdownNoToc` with `#[derive(Clone)]`
    |
236 + #[derive(Clone)]
237 | struct MarkdownNoToc(bool);
    |

---
    |
248 | #[derive(Clone, Debug)]
    |          ----- in this derive macro expansion
...
300 |     pub(crate) document_hidden: DocumentHidden,
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ the trait `std::clone::Clone` is not implemented for `DocumentHidden`
    |
   --> /rustc/9b1f8ff42d110b0ca138116745be921df5dc97e7/library/core/src/clone.rs:289:0
    |
    = note: in this expansion of `#[derive(Clone)]`
help: consider annotating `DocumentHidden` with `#[derive(Clone)]`
---
242 + #[derive(Clone)]
243 | struct NoEmitShared(bool);
    |

error[E0277]: the trait bound `HtmlNoSource: std::clone::Clone` is not satisfied
   --> src/librustdoc/config.rs:316:5
    |
248 | #[derive(Clone, Debug)]
    |          ----- in this derive macro expansion
...
316 |     pub(crate) html_no_source: HtmlNoSource,
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ the trait `std::clone::Clone` is not implemented for `HtmlNoSource`
    |
   --> /rustc/9b1f8ff42d110b0ca138116745be921df5dc97e7/library/core/src/clone.rs:289:0
    |
    = note: in this expansion of `#[derive(Clone)]`
help: consider annotating `HtmlNoSource` with `#[derive(Clone)]`
---
    |
248 | #[derive(Clone, Debug)]
    |          ----- in this derive macro expansion
...
319 |     pub(crate) output_to_stdout: OutputToStdout,
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ the trait `std::clone::Clone` is not implemented for `OutputToStdout`
    |
   --> /rustc/9b1f8ff42d110b0ca138116745be921df5dc97e7/library/core/src/clone.rs:289:0
    |
    = note: in this expansion of `#[derive(Clone)]`
help: consider annotating `OutputToStdout` with `#[derive(Clone)]`
---
245 + #[derive(Clone)]
246 | struct GenerateMacroExpansion(bool);
    |

error[E0277]: `ExternHTMLRootTakesPrecedence` doesn't implement `std::fmt::Debug`
   --> src/librustdoc/config.rs:272:5
    |
248 | #[derive(Clone, Debug)]
    |                 ----- in this derive macro expansion
...
272 |     pub(crate) extern_html_root_takes_precedence: ExternHTMLRootTakesPrecedence,
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ the trait `std::fmt::Debug` is not implemented for `ExternHTMLRootTakesPrecedence`
    |
   --> /rustc/9b1f8ff42d110b0ca138116745be921df5dc97e7/library/core/src/fmt/mod.rs:1092:4
    |
    = note: in this expansion of `#[derive(Debug)]`
    |
    = note: add `#[derive(Debug)]` to `ExternHTMLRootTakesPrecedence` or manually `impl std::fmt::Debug for ExternHTMLRootTakesPrecedence`
help: consider annotating `ExternHTMLRootTakesPrecedence` with `#[derive(Debug)]`
    |
240 + #[derive(Debug)]
241 | struct ExternHTMLRootTakesPrecedence(bool);
    |

error[E0277]: `EnableIndexPage` doesn't implement `std::fmt::Debug`
   --> src/librustdoc/config.rs:280:5
    |
---
   --> /rustc/9b1f8ff42d110b0ca138116745be921df5dc97e7/library/core/src/fmt/mod.rs:1092:4
    |
    = note: in this expansion of `#[derive(Debug)]`
    |
    = note: add `#[derive(Debug)]` to `EnableIndexPage` or manually `impl std::fmt::Debug for EnableIndexPage`
help: consider annotating `EnableIndexPage` with `#[derive(Debug)]`
    |
233 + #[derive(Debug)]
234 | struct EnableIndexPage(bool);
    |

error[E0277]: `MarkdownNoToc` doesn't implement `std::fmt::Debug`
   --> src/librustdoc/config.rs:291:5
    |
248 | #[derive(Clone, Debug)]
    |                 ----- in this derive macro expansion
...
291 |     pub(crate) markdown_no_toc: MarkdownNoToc,
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ the trait `std::fmt::Debug` is not implemented for `MarkdownNoToc`
    |
   --> /rustc/9b1f8ff42d110b0ca138116745be921df5dc97e7/library/core/src/fmt/mod.rs:1092:4
    |
    = note: in this expansion of `#[derive(Debug)]`
    |
    = note: add `#[derive(Debug)]` to `MarkdownNoToc` or manually `impl std::fmt::Debug for MarkdownNoToc`
help: consider annotating `MarkdownNoToc` with `#[derive(Debug)]`
    |
236 + #[derive(Debug)]
237 | struct MarkdownNoToc(bool);
    |

---
    |
248 | #[derive(Clone, Debug)]
    |                 ----- in this derive macro expansion
...
300 |     pub(crate) document_hidden: DocumentHidden,
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ the trait `std::fmt::Debug` is not implemented for `DocumentHidden`
    |
   --> /rustc/9b1f8ff42d110b0ca138116745be921df5dc97e7/library/core/src/fmt/mod.rs:1092:4
    |
    = note: in this expansion of `#[derive(Debug)]`
    |
    = note: add `#[derive(Debug)]` to `DocumentHidden` or manually `impl std::fmt::Debug for DocumentHidden`
help: consider annotating `DocumentHidden` with `#[derive(Debug)]`
    |
237 + #[derive(Debug)]
238 | struct DocumentHidden(bool);
    |

---
   --> /rustc/9b1f8ff42d110b0ca138116745be921df5dc97e7/library/core/src/fmt/mod.rs:1092:4
    |
    = note: in this expansion of `#[derive(Debug)]`
    |
    = note: add `#[derive(Debug)]` to `GenerateRedirectMap` or manually `impl std::fmt::Debug for GenerateRedirectMap`
help: consider annotating `GenerateRedirectMap` with `#[derive(Debug)]`
    |
238 + #[derive(Debug)]
239 | struct GenerateRedirectMap(bool);
    |

---
   --> /rustc/9b1f8ff42d110b0ca138116745be921df5dc97e7/library/core/src/fmt/mod.rs:1092:4
    |
    = note: in this expansion of `#[derive(Debug)]`
    |
    = note: add `#[derive(Debug)]` to `ShowTypeLayout` or manually `impl std::fmt::Debug for ShowTypeLayout`
help: consider annotating `ShowTypeLayout` with `#[derive(Debug)]`
    |
239 + #[derive(Debug)]
240 | struct ShowTypeLayout(bool);
    |

---
   --> /rustc/9b1f8ff42d110b0ca138116745be921df5dc97e7/library/core/src/fmt/mod.rs:1092:4
    |
    = note: in this expansion of `#[derive(Debug)]`
    |
    = note: add `#[derive(Debug)]` to `GenerateLinkToDefinition` or manually `impl std::fmt::Debug for GenerateLinkToDefinition`
help: consider annotating `GenerateLinkToDefinition` with `#[derive(Debug)]`
    |
241 + #[derive(Debug)]
242 | struct GenerateLinkToDefinition(bool);
    |

---
   --> /rustc/9b1f8ff42d110b0ca138116745be921df5dc97e7/library/core/src/fmt/mod.rs:1092:4
    |
    = note: in this expansion of `#[derive(Debug)]`
    |
    = note: add `#[derive(Debug)]` to `NoEmitShared` or manually `impl std::fmt::Debug for NoEmitShared`
help: consider annotating `NoEmitShared` with `#[derive(Debug)]`
    |
242 + #[derive(Debug)]
243 | struct NoEmitShared(bool);
    |

error[E0277]: `HtmlNoSource` doesn't implement `std::fmt::Debug`
   --> src/librustdoc/config.rs:316:5
    |
248 | #[derive(Clone, Debug)]
    |                 ----- in this derive macro expansion
...
316 |     pub(crate) html_no_source: HtmlNoSource,
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ the trait `std::fmt::Debug` is not implemented for `HtmlNoSource`
    |
   --> /rustc/9b1f8ff42d110b0ca138116745be921df5dc97e7/library/core/src/fmt/mod.rs:1092:4
    |
    = note: in this expansion of `#[derive(Debug)]`
    |
    = note: add `#[derive(Debug)]` to `HtmlNoSource` or manually `impl std::fmt::Debug for HtmlNoSource`
help: consider annotating `HtmlNoSource` with `#[derive(Debug)]`
    |
235 + #[derive(Debug)]
236 | struct HtmlNoSource(bool);
    |

error[E0277]: `OutputToStdout` doesn't implement `std::fmt::Debug`
   --> src/librustdoc/config.rs:319:5
    |
248 | #[derive(Clone, Debug)]
    |                 ----- in this derive macro expansion
...
319 |     pub(crate) output_to_stdout: OutputToStdout,
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ the trait `std::fmt::Debug` is not implemented for `OutputToStdout`
    |
   --> /rustc/9b1f8ff42d110b0ca138116745be921df5dc97e7/library/core/src/fmt/mod.rs:1092:4
    |
    = note: in this expansion of `#[derive(Debug)]`
    |
    = note: add `#[derive(Debug)]` to `OutputToStdout` or manually `impl std::fmt::Debug for OutputToStdout`
help: consider annotating `OutputToStdout` with `#[derive(Debug)]`
    |
243 + #[derive(Debug)]
244 | struct OutputToStdout(bool);
    |

---
   --> /rustc/9b1f8ff42d110b0ca138116745be921df5dc97e7/library/core/src/fmt/mod.rs:1092:4
    |
    = note: in this expansion of `#[derive(Debug)]`
    |
    = note: add `#[derive(Debug)]` to `DisableMinification` or manually `impl std::fmt::Debug for DisableMinification`
help: consider annotating `DisableMinification` with `#[derive(Debug)]`
    |
244 + #[derive(Debug)]
245 | struct DisableMinification(bool);
    |

---
error[E0308]: mismatched types
   --> src/librustdoc/config.rs:903:13
    |
903 |             extern_html_root_takes_precedence,
    |             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ expected `ExternHTMLRootTakesPrecedence`, found `bool`
    |
help: try wrapping the expression in `config::ExternHTMLRootTakesPrecedence`
    |
903 |             extern_html_root_takes_precedence: config::ExternHTMLRootTakesPrecedence(extern_html_root_takes_precedence),
    |             +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++                                 +

error[E0308]: mismatched types
   --> src/librustdoc/config.rs:906:13
    |
906 |             enable_index_page,
    |             ^^^^^^^^^^^^^^^^^ expected `EnableIndexPage`, found `bool`
    |
help: try wrapping the expression in `config::EnableIndexPage`
    |
906 |             enable_index_page: config::EnableIndexPage(enable_index_page),
    |             +++++++++++++++++++++++++++++++++++++++++++                 +

error[E0308]: mismatched types
   --> src/librustdoc/config.rs:909:13
    |
909 |             markdown_no_toc,
    |             ^^^^^^^^^^^^^^^ expected `MarkdownNoToc`, found `bool`
    |
help: try wrapping the expression in `config::MarkdownNoToc`
    |
909 |             markdown_no_toc: config::MarkdownNoToc(markdown_no_toc),
    |             +++++++++++++++++++++++++++++++++++++++               +

error[E0308]: mismatched types
   --> src/librustdoc/config.rs:912:13
    |
---
    |             ^^^^^^^^^^^^^^^ expected `DocumentHidden`, found `bool`
    |
help: try wrapping the expression in `config::DocumentHidden`
    |
913 |             document_hidden: config::DocumentHidden(document_hidden),
    |             ++++++++++++++++++++++++++++++++++++++++               +

error[E0308]: mismatched types
   --> src/librustdoc/config.rs:914:13
    |
---
    |                             ^^^^^ expected `NoEmitShared`, found `bool`
    |
help: try wrapping the expression in `config::NoEmitShared`
    |
921 |             no_emit_shared: config::NoEmitShared(false),
    |                             +++++++++++++++++++++     +

error[E0308]: mismatched types
   --> src/librustdoc/config.rs:922:13
    |
922 |             html_no_source,
    |             ^^^^^^^^^^^^^^ expected `HtmlNoSource`, found `bool`
    |
help: try wrapping the expression in `config::HtmlNoSource`
    |
922 |             html_no_source: config::HtmlNoSource(html_no_source),
    |             +++++++++++++++++++++++++++++++++++++              +

error[E0308]: mismatched types
   --> src/librustdoc/config.rs:923:13
    |
923 |             output_to_stdout,
    |             ^^^^^^^^^^^^^^^^ expected `OutputToStdout`, found `bool`
    |
help: try wrapping the expression in `config::OutputToStdout`
    |
923 |             output_to_stdout: config::OutputToStdout(output_to_stdout),
    |             +++++++++++++++++++++++++++++++++++++++++                +

error[E0308]: mismatched types
   --> src/librustdoc/config.rs:927:13
    |
---

error[E0308]: arguments to this function are incorrect
   --> src/librustdoc/core.rs:373:16
    |
373 |         cache: Cache::new(render_options.document_private, render_options.document_hidden),
    |                ^^^^^^^^^^ -------------------------------  ------------------------------ expected `bool`, found `DocumentHidden`
    |                           |
    |                           expected `bool`, found `DocumentPrivate`
    |
note: associated function defined here
   --> src/librustdoc/formats/cache.rs:146:19
    |
146 |     pub(crate) fn new(document_private: bool, document_hidden: bool) -> Self {
    |                   ^^^ ----------------------  ---------------------

error[E0308]: mismatched types
   --> src/librustdoc/formats/cache.rs:180:61
    |
180 |                 let location = e.location(Some(extern_url), extern_url_takes_precedence, dst, tcx);
    |                                  --------                   ^^^^^^^^^^^^^^^^^^^^^^^^^^^ expected `bool`, found `ExternHTMLRootTakesPrecedence`
    |                                  |
    |                                  arguments to this method are incorrect
    |
note: method defined here
   --> src/librustdoc/clean/types.rs:192:19
---

error[E0308]: mismatched types
   --> src/librustdoc/formats/cache.rs:196:40
    |
196 |                 e.location(extern_url, extern_url_takes_precedence, dst, tcx)
    |                   --------             ^^^^^^^^^^^^^^^^^^^^^^^^^^^ expected `bool`, found `ExternHTMLRootTakesPrecedence`
    |                   |
    |                   arguments to this method are incorrect
    |
note: method defined here
   --> src/librustdoc/clean/types.rs:192:19
---

error[E0600]: cannot apply unary operator `!` to type `HtmlNoSource`
   --> src/librustdoc/html/macro_expansion.rs:17:12
    |
 17 |         && !render_options.html_no_source
    |            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ cannot apply unary operator `!`
    |
note: an implementation of `std::ops::Not` might be missing for `HtmlNoSource`
   --> src/librustdoc/config.rs:235:1
    |
235 | struct HtmlNoSource(bool);
    | ^^^^^^^^^^^^^^^^^^^ must implement `std::ops::Not`
note: the trait `std::ops::Not` must be implemented
   --> /rustc/9b1f8ff42d110b0ca138116745be921df5dc97e7/library/core/src/ops/bit.rs:35:0

error[E0308]: mismatched types
  --> src/librustdoc/html/macro_expansion.rs:18:12
   |
16 |       if output_format == OutputFormat::Html
   |  ________-
17 | |         && !render_options.html_no_source
   | |_________________________________________- expected because this is `bool`
18 |           && render_options.generate_macro_expansion
   |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ expected `bool`, found `GenerateMacroExpansion`

error[E0600]: cannot apply unary operator `!` to type `HtmlNoSource`
   --> src/librustdoc/html/render/context.rs:535:35
    |
535 |         let mut include_sources = !html_no_source;
    |                                   ^^^^^^^^^^^^^^^ cannot apply unary operator `!`
    |
note: an implementation of `std::ops::Not` might be missing for `HtmlNoSource`
   --> src/librustdoc/config.rs:235:1
    |
235 | struct HtmlNoSource(bool);
    | ^^^^^^^^^^^^^^^^^^^ must implement `std::ops::Not`
note: the trait `std::ops::Not` must be implemented
---

error[E0308]: mismatched types
   --> src/librustdoc/html/render/context.rs:586:30
    |
586 |             redirections: if generate_redirect_map { Some(Default::default()) } else { None },
    |                              ^^^^^^^^^^^^^^^^^^^^^ expected `bool`, found `GenerateRedirectMap`

error[E0308]: mismatched types
   --> src/librustdoc/html/render/context.rs:587:13
    |
587 |             show_type_layout,
---
    |
612 |         if !no_emit_shared {
    |            ^^^^^^^^^^^^^^^ cannot apply unary operator `!`
    |
note: an implementation of `std::ops::Not` might be missing for `NoEmitShared`
   --> src/librustdoc/config.rs:242:1
    |
242 | struct NoEmitShared(bool);
    | ^^^^^^^^^^^^^^^^^^^ must implement `std::ops::Not`
note: the trait `std::ops::Not` must be implemented
   --> /rustc/9b1f8ff42d110b0ca138116745be921df5dc97e7/library/core/src/ops/bit.rs:35:0

error[E0308]: mismatched types
   --> src/librustdoc/html/render/write_shared.rs:117:33
    |
117 |             Some(index_page) if opt.enable_index_page => {
    |                                 ^^^^^^^^^^^^^^^^^^^^^ expected `bool`, found `EnableIndexPage`

error[E0308]: mismatched types
   --> src/librustdoc/html/render/write_shared.rs:126:21
    |
126 |             None if opt.enable_index_page => {
    |                     ^^^^^^^^^^^^^^^^^^^^^ expected `bool`, found `EnableIndexPage`

error[E0308]: mismatched types
   --> src/librustdoc/html/render/write_shared.rs:225:20
    |
225 |                 if opt.disable_minification { f.src_bytes } else { f.minified_bytes };
    |                    ^^^^^^^^^^^^^^^^^^^^^^^^ expected `bool`, found `DisableMinification`

error[E0308]: mismatched types
   --> src/librustdoc/json/mod.rs:124:29
    |
124 |                 out_dir: if options.output_to_stdout { None } else { Some(options.output) },
    |                             ^^^^^^^^^^^^^^^^^^^^^^^^ expected `bool`, found `OutputToStdout`

error[E0600]: cannot apply unary operator `!` to type `MarkdownNoToc`
   --> src/librustdoc/markdown.rs:82:12
    |
 82 |         if !options.markdown_no_toc {
    |            ^^^^^^^^^^^^^^^^^^^^^^^^ cannot apply unary operator `!`
    |
note: an implementation of `std::ops::Not` might be missing for `MarkdownNoToc`
   --> src/librustdoc/config.rs:236:1
    |
236 | struct MarkdownNoToc(bool);
    | ^^^^^^^^^^^^^^^^^^^^ must implement `std::ops::Not`
note: the trait `std::ops::Not` must be implemented
---
    |         -------------------------   ^^^^ expected `NoEmitShared`, found `bool`
    |         |
    |         expected due to the type of this binding
    |
help: try wrapping the expression in `config::NoEmitShared` (its field is private, but it's local to this crate and its privacy can be changed)
    |
278 |         renderopts.no_emit_shared = config::NoEmitShared(true);
    |                                     +++++++++++++++++++++    +

error[E0600]: cannot apply unary operator `!` to type `HtmlNoSource`
   --> src/librustdoc/lib.rs:762:27
    |
762 |     let include_sources = !opt.html_no_source;
    |                           ^^^^^^^^^^^^^^^^^^^ cannot apply unary operator `!`
    |
note: an implementation of `std::ops::Not` might be missing for `HtmlNoSource`
   --> src/librustdoc/config.rs:235:1
    |
235 | struct HtmlNoSource(bool);
    | ^^^^^^^^^^^^^^^^^^^ must implement `std::ops::Not`
note: the trait `std::ops::Not` must be implemented

@GuillaumeGomez
Copy link
Member

The code is much less good like this. ^^'

@fmease
Copy link
Member

fmease commented Feb 26, 2026

Moreover, in the first PR that attempted to address this (#147621, stalled), I requested these to be turned into enum { Yes, No }s (#147621 (comment)).

However, even that seems overkill. @GuillaumeGomez, should we just close issue #87752, PR #147621 and this PR, #153155?

@GuillaumeGomez
Copy link
Member

Yeah I think so. The added value is clearly too little to be worth it here. Closing all of them.

@rustbot rustbot removed the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label Feb 26, 2026
@fmease
Copy link
Member

fmease commented Feb 26, 2026

milosilo-dev, thank you for showing an interest in contributing to rustc and apologies for closing your PR. We should've realized a lot earlier that issue #87752 is not worth addressing. I hope this doesn't discourage you from contributing in the future though! Always happy to see more people working on Rust!

@milosilo-dev
Copy link
Author

milosilo-dev commented Feb 27, 2026

No problem, it took like 5 minutes to implement so I am not too worried. Thanks for the fast response.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

T-rustdoc Relevant to the rustdoc team, which will review and decide on the PR/issue.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants