Skip to content

Clean up some traits#156021

Open
nnethercote wants to merge 5 commits intorust-lang:mainfrom
nnethercote:clean-up-some-traits
Open

Clean up some traits#156021
nnethercote wants to merge 5 commits intorust-lang:mainfrom
nnethercote:clean-up-some-traits

Conversation

@nnethercote
Copy link
Copy Markdown
Contributor

@nnethercote nnethercote commented May 1, 2026

I was looking at various traits and found some unnecessary trait bounds, and some unnecessary traits. Details in individual commits.

r? @Nadrieril

@rustbot
Copy link
Copy Markdown
Collaborator

rustbot commented May 1, 2026

Some changes occurred in exhaustiveness checking

cc @Nadrieril

rustc_error_messages was changed

cc @TaKO8Ki

@rustbot rustbot added A-translation Area: Translation infrastructure, and migrating existing diagnostics to SessionDiagnostic 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 May 1, 2026
@rustbot
Copy link
Copy Markdown
Collaborator

rustbot commented May 1, 2026

Nadrieril is currently at their maximum review capacity.
They may take a while to respond.

@rust-log-analyzer

This comment has been minimized.

It has a single method and a single impl and the trait isn't directly
used. It can just become an inherent method.
When you have `impl Foo for Bar` and `Bar` has no generics it's useless
(and odd) to have `where Self: Baz` bounds on methods when the trait
itself doesn't have those bounds. This commit removes a few.
FWIW, note that `Diagnostic` doesn't have this bound.
@nnethercote nnethercote force-pushed the clean-up-some-traits branch from d7f14d3 to 9119225 Compare May 1, 2026 03:33
@rust-log-analyzer
Copy link
Copy Markdown
Collaborator

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

Click to see the possible cause of the failure (guessed by this bot)
  local time: Fri May  1 03:35:52 UTC 2026
  network time: Fri, 01 May 2026 03:35:52 GMT
##[endgroup]
sccache: Starting the server...
sccache: error: Server startup failed: cache storage failed to read: ConfigInvalid (permanent) at read => S3Error { code: "NoSuchBucket", message: "The specified bucket does not exist", resource: "", request_id: "1K1AZHQE18A8M48V" }

Context:
   uri: https://s3.us-west-1.amazonaws.com/rust-lang-ci-sccache2/.sccache_check
   response: Parts { status: 404, version: HTTP/1.1, headers: {"x-amz-request-id": "1K1AZHQE18A8M48V", "x-amz-id-2": "bCg8tcYfcWq6poWKOQDT7WHmJ4kaRu3WsiccWsvK3UCtGrP//HPOCpbxsmy/eKxatiePAMC94YTfke8qZeaOO9ldvfrOI5/Z", "content-type": "application/xml", "transfer-encoding": "chunked", "date": "Fri, 01 May 2026 03:35:52 GMT", "server": "AmazonS3"} }
   service: s3
   path: .sccache_check
   range: 0-

Backtrace:
---
[TIMING:end] compile::StdLink { compiler: Compiler { stage: 0, host: x86_64-unknown-linux-gnu, forced_compiler: false }, target_compiler: Compiler { stage: 0, host: x86_64-unknown-linux-gnu, forced_compiler: false }, target: x86_64-unknown-linux-gnu, crates: [], force_recompile: false } -- 0.001
##[group]Building stage1 compiler artifacts (stage0 -> stage1, x86_64-unknown-linux-gnu)
error: process didn't exit successfully: `sccache /checkout/obj/build/bootstrap/debug/rustc -vV` (exit status: 2)
--- stderr
sccache: error: Server startup failed: cache storage failed to read: ConfigInvalid (permanent) at read => S3Error { code: "NoSuchBucket", message: "The specified bucket does not exist", resource: "", request_id: "P9636RSR62Y0P898" }

Context:
   uri: https://s3.us-west-1.amazonaws.com/rust-lang-ci-sccache2/.sccache_check
   response: Parts { status: 404, version: HTTP/1.1, headers: {"x-amz-request-id": "P9636RSR62Y0P898", "x-amz-id-2": "as/7i9zfbHJvTZ+XTImWsnvMwJnHj/EC6mIPH9ac8mHB/PU3LjphiAHEFFrZE0tpvKwwBnxT5gI=", "content-type": "application/xml", "transfer-encoding": "chunked", "date": "Fri, 01 May 2026 03:36:54 GMT", "server": "AmazonS3"} }
   service: s3
   path: .sccache_check
   range: 0-

Backtrace:
---
  11: <unknown>
  12: <unknown>


Run with SCCACHE_LOG=debug SCCACHE_NO_DAEMON=1 to get more information

Bootstrap failed while executing `build --stage 2 compiler rustdoc`
Build completed unsuccessfully in 0:00:26
  local time: Fri May  1 03:36:55 UTC 2026
  network time: Fri, 01 May 2026 03:36:55 GMT

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

Labels

A-translation Area: Translation infrastructure, and migrating existing diagnostics to SessionDiagnostic 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.

4 participants