Skip to content

Docs(lib): Fix extract_if docs #141108

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

Merged
merged 7 commits into from
May 25, 2025
Merged

Conversation

PaulDance
Copy link
Contributor

@PaulDance PaulDance commented May 17, 2025

Various fixes to the documentation comments of the several extract_if collection methods available. It originally started with a small typo fix in Vec's spotted when reading the 1.87 release notes, but then by looking at the others' for comparison in order to try determining what was the intended sentence, some inconsistencies were spotted. Therefore, some other changes are also proposed here to reduce these avoidable differences, going more and more nit-picky along the way. See the individual commits for more details about each change.

@rustbot label T-libs A-collections A-docs

PaulDance added 7 commits May 17, 2025 02:09
…tence

As inspired by the equivalent methods from other collection types.

Signed-off-by: Paul Mabileau <paul.mabileau@harfanglab.fr>
…alue`

A minor change, but it seemed interesting to unify this one's
description, especially considering all the other equivalents use
`element` as well.

Signed-off-by: Paul Mabileau <paul.mabileau@harfanglab.fr>
…owing ones

This also seems like a small mistake: the first main sentence is put in
the same paragraph as the other two following ones while other
equivalents all have it split. Therefore, do the same here.

Signed-off-by: Paul Mabileau <paul.mabileau@harfanglab.fr>
Also fixes `HashSet`'s that incorrectly designated itself as a `list`.

Signed-off-by: Paul Mabileau <paul.mabileau@harfanglab.fr>
Take the one from `BTreeMap` that seems the best-worded and most
precise among the available variations.

Signed-off-by: Paul Mabileau <paul.mabileau@harfanglab.fr>
Make it consistent in this regard with `BTreeMap`'s.

Signed-off-by: Paul Mabileau <paul.mabileau@harfanglab.fr>
Signed-off-by: Paul Mabileau <paul.mabileau@harfanglab.fr>
@rustbot
Copy link
Collaborator

rustbot commented May 17, 2025

r? @Mark-Simulacrum

rustbot has assigned @Mark-Simulacrum.
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

@rustbot rustbot added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-libs Relevant to the library team, which will review and decide on the PR/issue. A-collections Area: `std::collections` A-docs Area: Documentation for any part of the project, including the compiler, standard library, and tools labels May 17, 2025
@Mark-Simulacrum
Copy link
Member

@bors r+ rollup

@bors
Copy link
Collaborator

bors commented May 25, 2025

📌 Commit b1d7480 has been approved by Mark-Simulacrum

It is now in the queue for this repository.

@bors bors added S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels May 25, 2025
bors added a commit that referenced this pull request May 25, 2025
Rollup of 4 pull requests

Successful merges:

 - #139831 (rustdoc: on mobile, make the sidebar full width and linewrap)
 - #140950 (More option optimization tests)
 - #141108 (Docs(lib): Fix `extract_if` docs)
 - #141361 (use `cfg_select!` to select the right `VaListImpl` definition)

r? `@ghost`
`@rustbot` modify labels: rollup
@bors bors merged commit 3338ff7 into rust-lang:master May 25, 2025
6 checks passed
@rustbot rustbot added this to the 1.89.0 milestone May 25, 2025
rust-timer added a commit that referenced this pull request May 25, 2025
Rollup merge of #141108 - PaulDance:fix-extract_if-docs, r=Mark-Simulacrum

Docs(lib): Fix `extract_if` docs

Various fixes to the documentation comments of the several `extract_if` collection methods available. It originally started with a small typo fix in `Vec`'s spotted when reading the 1.87 release notes, but then by looking at the others' for comparison in order to try determining what was the intended sentence, some inconsistencies were spotted. Therefore, some other changes are also proposed here to reduce these avoidable differences, going more and more nit-picky along the way. See the individual commits for more details about each change.

`@rustbot` label T-libs A-collections A-docs
@PaulDance PaulDance deleted the fix-extract_if-docs branch May 25, 2025 19:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-collections Area: `std::collections` A-docs Area: Documentation for any part of the project, including the compiler, standard library, and tools S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. T-libs Relevant to the library team, which will review and decide on the PR/issue.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants