Skip to content

Clarify documentation of Option::{zip, zip_with}().#157206

Open
kpreid wants to merge 1 commit into
rust-lang:mainfrom
kpreid:zip-doc
Open

Clarify documentation of Option::{zip, zip_with}().#157206
kpreid wants to merge 1 commit into
rust-lang:mainfrom
kpreid:zip-doc

Conversation

@kpreid
Copy link
Copy Markdown
Contributor

@kpreid kpreid commented May 31, 2026

Instead of saying that zip() zips (which is nearly useless because either people already understood the function name and don’t need the introduction, or they didn’t and reiterating it doesn’t help), we can explain what it does more explicitly, in only a few more words.

This brings the first paragraphs closer in meaning to the second paragraphs, but they are still distinct: the first paragraph explains the overall goal without individual cases, and the second paragraph explains the full behavior case-by-case.

@rustbot label +A-docs

Instead of saying that `zip()` zips (which is nearly useless because
either people already understood the function name and don’t need the
introduction, or they didn’t and reiterating it doesn’t help), we can
explain what it does more explicitly, in only a few more words.

This brings the first paragraphs closer in meaning to the second
paragraphs, but they are still distinct: the first paragraph explains
the overall goal without individual cases, and the second paragraph
explains the full behavior case-by-case.
@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. labels May 31, 2026
@rustbot
Copy link
Copy Markdown
Collaborator

rustbot commented May 31, 2026

r? @jhpratt

rustbot has assigned @jhpratt.
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: libs
  • libs expanded to 7 candidates
  • Random selection from Mark-Simulacrum, jhpratt

@rustbot rustbot added the A-docs Area: Documentation for any part of the project, including the compiler, standard library, and tools label May 31, 2026
@jhpratt
Copy link
Copy Markdown
Member

jhpratt commented May 31, 2026

@bors r+ rollup

@rust-bors
Copy link
Copy Markdown
Contributor

rust-bors Bot commented May 31, 2026

📌 Commit 1ac6f6b has been approved by jhpratt

It is now in the queue for this repository.

@rust-bors rust-bors Bot 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 31, 2026
jhpratt added a commit to jhpratt/rust that referenced this pull request May 31, 2026
Clarify documentation of `Option::{zip, zip_with}()`.

Instead of saying that `zip()` zips (which is nearly useless because either people already understood the function name and don’t need the introduction, or they didn’t and reiterating it doesn’t help), we can explain what it does more explicitly, in only a few more words.

This brings the first paragraphs closer in meaning to the second paragraphs, but they are still distinct: the first paragraph explains the overall goal without individual cases, and the second paragraph explains the full behavior case-by-case.

@rustbot label +A-docs
rust-bors Bot pushed a commit that referenced this pull request May 31, 2026
Rollup of 4 pull requests

Successful merges:

 - #156688 (Manually load GDB visualizers on windows for GDB tests)
 - #156995 (Bootstrap update)
 - #157156 (Expose an API for polymorphic drop glue translation)
 - #157206 (Clarify documentation of `Option::{zip, zip_with}()`.)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

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.

3 participants