Skip to content
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

Fix a typo in the alloc::string::String docs #122707

Merged
merged 2 commits into from
Mar 26, 2024
Merged

Fix a typo in the alloc::string::String docs #122707

merged 2 commits into from
Mar 26, 2024

Conversation

reedwoodruff
Copy link
Contributor

No description provided.

@rustbot
Copy link
Collaborator

rustbot commented Mar 18, 2024

Thanks for the pull request, and welcome! The Rust team is excited to review your changes, and you should hear from @Mark-Simulacrum (or someone else) some time within the next two weeks.

Please see the contribution instructions for more information. Namely, in order to ensure the minimum review times lag, PR authors and assigned reviewers should ensure that the review label (S-waiting-on-review and S-waiting-on-author) stays updated, invoking these commands when appropriate:

  • @rustbot author: the review is finished, PR author should check the comments and take action accordingly
  • @rustbot review: the author is ready for a review, this PR will be queued again in the reviewer's queue

@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 Mar 18, 2024
Copy link
Member

@compiler-errors compiler-errors left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think this is a typo. Instead, I think this is a case of dropping "that" in a relative clause -- i.e. this should be read "The pointer points to an internal buffer [that] String uses to store its data."

The internal buffer is not named String, so I don't believe the correction is grammatical.

@workingjubilee
Copy link
Member

I agree, this is not a fix.

@jhpratt
Copy link
Member

jhpratt commented Mar 18, 2024

As a native English speaker (as I believe others in this PR so far are), I agree with @compiler-errors. There is an implicit "that" that is omitted. Doing so is correct, but would probably be clearer to non-native speakers if present. I think that would be the change to make, if any.

@workingjubilee
Copy link
Member

Yeah, that seems like it would be fine.

@reedwoodruff
Copy link
Contributor Author

reedwoodruff commented Mar 22, 2024

@compiler-errors
My mistake, I misunderstood the intent of the sentence. Thank you for catching this. Maybe it would be clearer to change "an internal buffer" to "the internal buffer"? But probably the bigger point is adding a "which" or "that".

The pointer points to an internal buffer String uses to store its data.
The pointer points to an the internal buffer which String uses to store its data.

I think that is what threw me -- it felt like "String" was the name of the internal buffer. I agree now that it is technically correct as-is, but this might help reduce misunderstandings.

@workingjubilee
Copy link
Member

@reedwoodruff Yeah, that sounds fine.

@workingjubilee
Copy link
Member

@rustbot author

@rustbot rustbot added S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Mar 22, 2024
@workingjubilee
Copy link
Member

This looks good to me. Thanks!

@bors r+ rollup

@bors
Copy link
Contributor

bors commented Mar 25, 2024

📌 Commit 58e2ad3 has been approved by workingjubilee

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-author Status: This is awaiting some action (such as code changes or more information) from the author. labels Mar 25, 2024
workingjubilee added a commit to workingjubilee/rustc that referenced this pull request Mar 25, 2024
…orkingjubilee

Fix a typo in the alloc::string::String docs
bors added a commit to rust-lang-ci/rust that referenced this pull request Mar 25, 2024
…kingjubilee

Rollup of 10 pull requests

Successful merges:

 - rust-lang#122707 (Fix a typo in the alloc::string::String docs)
 - rust-lang#122769 (extend comments for reachability set computation)
 - rust-lang#122892 (fix(bootstrap/dist): use versioned dirs when vendoring)
 - rust-lang#122896 (Update stdarch submodule)
 - rust-lang#122923 (In `pretty_print_type()`, print `async fn` futures' paths instead of spans.)
 - rust-lang#122950 (Add regression tests for rust-lang#101903)
 - rust-lang#122958 (Port backtrace dylib-dep test to a ui test)
 - rust-lang#123039 (Update books)
 - rust-lang#123044 (`Instance` is `Copy`)
 - rust-lang#123051 (did I mention that tests are super cool? )

r? `@ghost`
`@rustbot` modify labels: rollup
bors added a commit to rust-lang-ci/rust that referenced this pull request Mar 25, 2024
…kingjubilee

Rollup of 10 pull requests

Successful merges:

 - rust-lang#122707 (Fix a typo in the alloc::string::String docs)
 - rust-lang#122769 (extend comments for reachability set computation)
 - rust-lang#122892 (fix(bootstrap/dist): use versioned dirs when vendoring)
 - rust-lang#122896 (Update stdarch submodule)
 - rust-lang#122923 (In `pretty_print_type()`, print `async fn` futures' paths instead of spans.)
 - rust-lang#122950 (Add regression tests for rust-lang#101903)
 - rust-lang#123039 (Update books)
 - rust-lang#123042 (Import the 2021 prelude in the core crate)
 - rust-lang#123044 (`Instance` is `Copy`)
 - rust-lang#123051 (did I mention that tests are super cool? )

r? `@ghost`
`@rustbot` modify labels: rollup
bors added a commit to rust-lang-ci/rust that referenced this pull request Mar 26, 2024
…kingjubilee

Rollup of 10 pull requests

Successful merges:

 - rust-lang#122707 (Fix a typo in the alloc::string::String docs)
 - rust-lang#122769 (extend comments for reachability set computation)
 - rust-lang#122892 (fix(bootstrap/dist): use versioned dirs when vendoring)
 - rust-lang#122896 (Update stdarch submodule)
 - rust-lang#122923 (In `pretty_print_type()`, print `async fn` futures' paths instead of spans.)
 - rust-lang#122950 (Add regression tests for rust-lang#101903)
 - rust-lang#123039 (Update books)
 - rust-lang#123042 (Import the 2021 prelude in the core crate)
 - rust-lang#123044 (`Instance` is `Copy`)
 - rust-lang#123051 (did I mention that tests are super cool? )

r? `@ghost`
`@rustbot` modify labels: rollup
@bors bors merged commit c35e971 into rust-lang:master Mar 26, 2024
11 checks passed
@rustbot rustbot added this to the 1.79.0 milestone Mar 26, 2024
rust-timer added a commit to rust-lang-ci/rust that referenced this pull request Mar 26, 2024
Rollup merge of rust-lang#122707 - reedwoodruff:string_docs_typo, r=workingjubilee

Fix a typo in the alloc::string::String docs
@reedwoodruff reedwoodruff deleted the string_docs_typo branch April 2, 2024 20:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
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.

7 participants