Skip to content

Conversation

@estebank
Copy link
Contributor

Makes the use expressions significantly shorter.

Makes the use expressions significantly shorter.
@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 Jan 15, 2026
@rustbot
Copy link
Collaborator

rustbot commented Jan 15, 2026

r? @chenyukang

rustbot has assigned @chenyukang.
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

Copy link
Contributor

@dianne dianne left a comment

Choose a reason for hiding this comment

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

@rust-bors
Copy link
Contributor

rust-bors bot commented Jan 16, 2026

📌 Commit b4781c8 has been approved by dianne

It is now in the queue for this repository.

@rust-bors rust-bors bot added the S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. label Jan 16, 2026
@rust-bors rust-bors bot removed the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label Jan 16, 2026
@Zalathar
Copy link
Member

What’s the status of feature(default_field_values) in rust-analyzer these days?

If we end up with more source files that can’t be opened without triggering unavoidable bogus IDE errors, that seems worse than any benefit gained from the shorter syntax.

matthiaskrgr added a commit to matthiaskrgr/rust that referenced this pull request Jan 16, 2026
Use default field values in a few more cases

Makes the use expressions significantly shorter.
matthiaskrgr added a commit to matthiaskrgr/rust that referenced this pull request Jan 16, 2026
Use default field values in a few more cases

Makes the use expressions significantly shorter.
@dianne
Copy link
Contributor

dianne commented Jan 16, 2026

What’s the status of feature(default_field_values) in rust-analyzer these days?

Oh, huh, it looks like it produces "missing struct field" errors on use. I thought I'd used it successfully in the past, but I guess I must have misremembered.

@dianne
Copy link
Contributor

dianne commented Jan 16, 2026

Given that, if it's not too late, @bors r-
I think default field values adds a nice amount of clarity here, but I don't think it's worth the r-a errors. Sorry for the hasty decision.

@rust-bors rust-bors bot added the S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. label Jan 16, 2026
@rust-bors
Copy link
Contributor

rust-bors bot commented Jan 16, 2026

Commit b4781c8 has been unapproved.

@rust-bors rust-bors bot removed the S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. label Jan 16, 2026
rust-bors bot pushed a commit that referenced this pull request Jan 16, 2026
Rollup of 4 pull requests

Successful merges:

 - #151155 (THIR patterns: Always use type `str` for string-constant-value nodes)
 - #151166 (fix: Do not delay E0107 when there exists an assoc ty with the same name)
 - #151172 (Use default field values in a few more cases)
 - #151185 (Disable `dump-ice-to-disk` on `i686-pc-windows-msvc`)

r? @ghost
@ShoyuVanilla
Copy link
Member

ShoyuVanilla commented Jan 16, 2026

What’s the status of feature(default_field_values) in rust-analyzer these days?

If we end up with more source files that can’t be opened without triggering unavoidable bogus IDE errors, that seems worse than any benefit gained from the shorter syntax.

To elaborate on the current status of rust-analyzer,

@dianne
Copy link
Contributor

dianne commented Jan 16, 2026

Nice! I'll happily re-approve this once the feature's supported. In the mean time, maybe let's say this is blocked so it's not labeled as waiting on author or review? @rustbot blocked

@rustbot rustbot added S-blocked Status: Blocked on something else such as an RFC or other implementation work. and removed S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. labels Jan 16, 2026
@dianne
Copy link
Contributor

dianne commented Jan 27, 2026

Looks like rust-lang/rust-analyzer#21408 is merged. I assume that means it'll be in next Monday's r-a release? I'll check back in then and fire off the merge if it's there (or r=me at that point)

@dianne
Copy link
Contributor

dianne commented Feb 2, 2026

@bors r+ rollup

@rust-bors
Copy link
Contributor

rust-bors bot commented Feb 2, 2026

📋 This PR cannot be approved because it currently has the following label: S-blocked.

@dianne
Copy link
Contributor

dianne commented Feb 2, 2026

@rustbot review

@rustbot rustbot added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. and removed S-blocked Status: Blocked on something else such as an RFC or other implementation work. labels Feb 2, 2026
@dianne
Copy link
Contributor

dianne commented Feb 2, 2026

@bors r+ rollup

@rust-bors
Copy link
Contributor

rust-bors bot commented Feb 2, 2026

📌 Commit b4781c8 has been approved by dianne

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 Feb 2, 2026
JonathanBrouwer added a commit to JonathanBrouwer/rust that referenced this pull request Feb 2, 2026
…ianne

Use default field values in a few more cases

Makes the use expressions significantly shorter.
rust-bors bot pushed a commit that referenced this pull request Feb 2, 2026
…uwer

Rollup of 11 pull requests

Successful merges:

 - #150992 (link modifier `export-symbols`: export all global symbols from selected uptream c static libraries)
 - #151695 (compiletest: Support `--extern` modifiers with `proc-macro` directive)
 - #151938 (Use `#![feature(adt_const_params)]` for static query flags)
 - #151172 (Use default field values in a few more cases)
 - #151825 (more float constants)
 - #151870 (regression test for alias-relate changes in lub)
 - #151902 (explain why we dont skip some of this work when there are field projections)
 - #151974 (Update documentation for `Result::ok()`)
 - #151978 (Query cleanups)
 - #151979 (Fix uninitialized UEFI globals in tests)
 - #151992 (Port `#[rustc_hidden_type_of_opaque]` to attribute parser)
JonathanBrouwer added a commit to JonathanBrouwer/rust that referenced this pull request Feb 2, 2026
…ianne

Use default field values in a few more cases

Makes the use expressions significantly shorter.
rust-bors bot pushed a commit that referenced this pull request Feb 2, 2026
…uwer

Rollup of 12 pull requests

Successful merges:

 - #149596 (resolve: Report more visibility-related early resolution ambiguities for imports)
 - #151695 (compiletest: Support `--extern` modifiers with `proc-macro` directive)
 - #151938 (Use `#![feature(adt_const_params)]` for static query flags)
 - #151172 (Use default field values in a few more cases)
 - #151825 (more float constants)
 - #151870 (regression test for alias-relate changes in lub)
 - #151872 (Add inline syntax for diagnostic messages)
 - #151902 (explain why we dont skip some of this work when there are field projections)
 - #151909 (Skip overlapping spans in argument error suggestions)
 - #151978 (Query cleanups)
 - #151979 (Fix uninitialized UEFI globals in tests)
 - #151992 (Port `#[rustc_hidden_type_of_opaque]` to attribute parser)
rust-bors bot pushed a commit that referenced this pull request Feb 2, 2026
…uwer

Rollup of 12 pull requests

Successful merges:

 - #149596 (resolve: Report more visibility-related early resolution ambiguities for imports)
 - #151695 (compiletest: Support `--extern` modifiers with `proc-macro` directive)
 - #151938 (Use `#![feature(adt_const_params)]` for static query flags)
 - #151172 (Use default field values in a few more cases)
 - #151825 (more float constants)
 - #151870 (regression test for alias-relate changes in lub)
 - #151872 (Add inline syntax for diagnostic messages)
 - #151902 (explain why we dont skip some of this work when there are field projections)
 - #151909 (Skip overlapping spans in argument error suggestions)
 - #151978 (Query cleanups)
 - #151979 (Fix uninitialized UEFI globals in tests)
 - #151992 (Port `#[rustc_hidden_type_of_opaque]` to attribute parser)
rust-bors bot pushed a commit that referenced this pull request Feb 3, 2026
…uwer

Rollup of 12 pull requests

Successful merges:

 - #149596 (resolve: Report more visibility-related early resolution ambiguities for imports)
 - #151695 (compiletest: Support `--extern` modifiers with `proc-macro` directive)
 - #151938 (Use `#![feature(adt_const_params)]` for static query flags)
 - #151172 (Use default field values in a few more cases)
 - #151825 (more float constants)
 - #151870 (regression test for alias-relate changes in lub)
 - #151872 (Add inline syntax for diagnostic messages)
 - #151902 (explain why we dont skip some of this work when there are field projections)
 - #151909 (Skip overlapping spans in argument error suggestions)
 - #151978 (Query cleanups)
 - #151979 (Fix uninitialized UEFI globals in tests)
 - #151992 (Port `#[rustc_hidden_type_of_opaque]` to attribute parser)
@rust-bors rust-bors bot merged commit 5144366 into rust-lang:main Feb 3, 2026
11 checks passed
@rustbot rustbot added this to the 1.95.0 milestone Feb 3, 2026
rust-timer added a commit that referenced this pull request Feb 3, 2026
Rollup merge of #151172 - estebank:default-field-values, r=dianne

Use default field values in a few more cases

Makes the use expressions significantly shorter.
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-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.

6 participants