Skip to content

Conversation

m-ou-se
Copy link
Member

@m-ou-se m-ou-se commented Aug 15, 2025

Not to be merged; just an experiment.

I'm curious how many crates rely on the Default for [T; 0] implementation not having a T: Default bound. Let's do a crater check run to find out. :)

@m-ou-se m-ou-se self-assigned this Aug 15, 2025
@m-ou-se m-ou-se added the S-experimental Status: Ongoing experiment that does not require reviewing and won't be merged in its current state. label Aug 15, 2025
@rustbot rustbot added S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. T-libs Relevant to the library team, which will review and decide on the PR/issue. labels Aug 15, 2025
@m-ou-se
Copy link
Member Author

m-ou-se commented Aug 15, 2025

@bors try

rust-bors bot added a commit that referenced this pull request Aug 15, 2025
Experiment: Add `where T: Default` to `Default for [T; 0]` impl.
@rust-bors

This comment has been minimized.

@m-ou-se m-ou-se removed the S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. label Aug 15, 2025
@rust-bors
Copy link

rust-bors bot commented Aug 15, 2025

☀️ Try build successful (CI)
Build commit: 099af82 (099af82bc034c1e4895c90e5407fafdd61976cdb, parent: ba412a6e70ac84641be7764d088acabd0eb3fa39)

@m-ou-se
Copy link
Member Author

m-ou-se commented Aug 15, 2025

@craterbot check

@craterbot
Copy link
Collaborator

👌 Experiment pr-145457 created and queued.
🤖 Automatically detected try build 099af82
🔍 You can check out the queue and this experiment's details.

ℹ️ Crater is a tool to run experiments across parts of the Rust ecosystem. Learn more

@craterbot craterbot added S-waiting-on-crater Status: Waiting on a crater run to be completed. and removed S-experimental Status: Ongoing experiment that does not require reviewing and won't be merged in its current state. labels Aug 15, 2025
@craterbot
Copy link
Collaborator

🚧 Experiment pr-145457 is now running

ℹ️ Crater is a tool to run experiments across parts of the Rust ecosystem. Learn more

@craterbot
Copy link
Collaborator

🎉 Experiment pr-145457 is completed!
📊 75 regressed and 5 fixed (683072 total)
📰 Open the summary report.

⚠️ If you notice any spurious failure please add them to the denylist!
ℹ️ Crater is a tool to run experiments across parts of the Rust ecosystem. Learn more

@craterbot craterbot added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. and removed S-waiting-on-crater Status: Waiting on a crater run to be completed. labels Aug 17, 2025
@ais523
Copy link

ais523 commented Sep 14, 2025

Zalathar added a commit to Zalathar/rust that referenced this pull request Sep 15, 2025
…-errors

Note some previous attempts to change the Default impl for `[T; 0]`

Recently, rust-lang#145457 experimented with changing the Default impl for `[T; 0]`.

Subsequently, rust-lang#146531 also aimed to perform a similar experiment.

It seems like a good idea to add some links to the relevant source code, so that the historical context of this tricky topic is easier to find.
Zalathar added a commit to Zalathar/rust that referenced this pull request Sep 15, 2025
…-errors

Note some previous attempts to change the Default impl for `[T; 0]`

Recently, rust-lang#145457 experimented with changing the Default impl for `[T; 0]`.

Subsequently, rust-lang#146531 also aimed to perform a similar experiment.

It seems like a good idea to add some links to the relevant source code, so that the historical context of this tricky topic is easier to find.
Zalathar added a commit to Zalathar/rust that referenced this pull request Sep 15, 2025
…-errors

Note some previous attempts to change the Default impl for `[T; 0]`

Recently, rust-lang#145457 experimented with changing the Default impl for `[T; 0]`.

Subsequently, rust-lang#146531 also aimed to perform a similar experiment.

It seems like a good idea to add some links to the relevant source code, so that the historical context of this tricky topic is easier to find.
matthiaskrgr added a commit to matthiaskrgr/rust that referenced this pull request Sep 15, 2025
…-errors

Note some previous attempts to change the Default impl for `[T; 0]`

Recently, rust-lang#145457 experimented with changing the Default impl for `[T; 0]`.

Subsequently, rust-lang#146531 also aimed to perform a similar experiment.

It seems like a good idea to add some links to the relevant source code, so that the historical context of this tricky topic is easier to find.
matthiaskrgr added a commit to matthiaskrgr/rust that referenced this pull request Sep 15, 2025
…-errors

Note some previous attempts to change the Default impl for `[T; 0]`

Recently, rust-lang#145457 experimented with changing the Default impl for `[T; 0]`.

Subsequently, rust-lang#146531 also aimed to perform a similar experiment.

It seems like a good idea to add some links to the relevant source code, so that the historical context of this tricky topic is easier to find.
rust-timer added a commit that referenced this pull request Sep 16, 2025
Rollup merge of #146533 - Zalathar:array-default, r=compiler-errors

Note some previous attempts to change the Default impl for `[T; 0]`

Recently, #145457 experimented with changing the Default impl for `[T; 0]`.

Subsequently, #146531 also aimed to perform a similar experiment.

It seems like a good idea to add some links to the relevant source code, so that the historical context of this tricky topic is easier to find.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
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.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants