Skip to content

fix: correct typos and improve comments in compiler code #136384

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

Closed
wants to merge 5 commits into from

Conversation

RubinovaAn1097
Copy link

  • Replaced “unstalled” with “uninstalled” and “thie” → “this” in comments.
  • Fixed “replacable” to “replaceable.”
  • Tweaked wording in a few spots for clarity.
  • No logic changes—just doc/comment updates.

@rustbot
Copy link
Collaborator

rustbot commented Feb 1, 2025

Thanks for the pull request, and welcome! The Rust team is excited to review your changes, and you should hear from @lcnr (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-compiler Relevant to the compiler team, which will review and decide on the PR/issue. labels Feb 1, 2025
@rustbot
Copy link
Collaborator

rustbot commented Feb 1, 2025

The Miri subtree was changed

cc @rust-lang/miri

Some changes occurred to MIR optimizations

cc @rust-lang/wg-mir-opt

@rust-log-analyzer
Copy link
Collaborator

The job x86_64-gnu-llvm-18 failed! Check out the build log: (web) (plain)

Click to see the possible cause of the failure (guessed by this bot)
#21 exporting to docker image format
#21 sending tarball 28.9s done
#21 DONE 31.7s
##[endgroup]
Setting extra environment values for docker:  --env ENABLE_GCC_CODEGEN=1 --env GCC_EXEC_PREFIX=/usr/lib/gcc/
[CI_JOB_NAME=x86_64-gnu-llvm-18]
debug: `DISABLE_CI_RUSTC_IF_INCOMPATIBLE` configured.
---
sccache: Starting the server...
##[group]Configure the build
configure: processing command line
configure: 
configure: build.configure-args := ['--build=x86_64-unknown-linux-gnu', '--llvm-root=/usr/lib/llvm-18', '--enable-llvm-link-shared', '--set', 'rust.randomize-layout=true', '--set', 'rust.thin-lto-import-instr-limit=10', '--enable-verbose-configure', '--enable-sccache', '--disable-manage-submodules', '--enable-locked-deps', '--enable-cargo-native-static', '--set', 'rust.codegen-units-std=1', '--set', 'dist.compression-profile=balanced', '--dist-compression-formats=xz', '--set', 'rust.lld=false', '--disable-dist-src', '--release-channel=nightly', '--enable-debug-assertions', '--enable-overflow-checks', '--enable-llvm-assertions', '--set', 'rust.verify-llvm-ir', '--set', 'rust.codegen-backends=llvm,cranelift,gcc', '--set', 'llvm.static-libstdcpp', '--enable-new-symbol-mangling']
configure: target.x86_64-unknown-linux-gnu.llvm-config := /usr/lib/llvm-18/bin/llvm-config
configure: llvm.link-shared     := True
configure: rust.randomize-layout := True
configure: rust.thin-lto-import-instr-limit := 10
---
   Compiling rustc_mir_build v0.0.0 (/checkout/compiler/rustc_mir_build)
   Compiling rustc_codegen_llvm v0.0.0 (/checkout/compiler/rustc_codegen_llvm)
   Compiling rustc_passes v0.0.0 (/checkout/compiler/rustc_passes)
   Compiling rustc_hir_typeck v0.0.0 (/checkout/compiler/rustc_hir_typeck)
error[E0599]: no method named `drain_uninstalled_obligations` found for struct `RefMut<'_, Box<dyn TraitEngine<'tcx, FulfillmentError<'tcx>>>>` in the current scope
   --> compiler/rustc_hir_typeck/src/fn_ctxt/_impl.rs:653:58
    |
653 |                 .extend(self.fulfillment_cx.borrow_mut().drain_uninstalled_obligations(&self.infcx));
    |
    = note: the full type name has been written to '/checkout/obj/build/x86_64-unknown-linux-gnu/stage0-rustc/x86_64-unknown-linux-gnu/release/deps/rustc_hir_typeck-497c32004ef9a228.long-type-18292553422879761999.txt'
    = note: consider using `--verbose` to print the full type name to the console
help: there is a method `drain_unstalled_obligations` with a similar name
help: there is a method `drain_unstalled_obligations` with a similar name
    |
653 |                 .extend(self.fulfillment_cx.borrow_mut().drain_unstalled_obligations(&self.infcx));

   Compiling rustc_mir_transform v0.0.0 (/checkout/compiler/rustc_mir_transform)
For more information about this error, try `rustc --explain E0599`.
error: could not compile `rustc_hir_typeck` (lib) due to 1 previous error

@saethlin
Copy link
Member

saethlin commented Feb 1, 2025

We have gotten a number of typo-fixing PRs recently that look like either identify farming or seeking of extrinsic rewards. This looks like one of those, especially because it doesn't compile, and one of the changes is wrong.

@RalfJung
Copy link
Member

RalfJung commented Feb 1, 2025 via email

@RubinovaAn1097

This comment was marked as spam.

@RubinovaAn1097

This comment was marked as spam.

@workingjubilee
Copy link
Member

hello! sorry for any confusion, but we actually are treating it on the merit.

we have plenty of typos in our user-facing documentation for which we are always happy to accept PRs for, but typo fixes that are confined to a random smattering of internal compiler comments are not useful. they are in fact churn that outweighs the benefit.

@rust-lang rust-lang locked as spam and limited conversation to collaborators Feb 1, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-compiler Relevant to the compiler 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