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

x/tools/gopls: provide quickfix for composite literals with unkeyed fields #53062

Open
hyangah opened this issue May 25, 2022 · 3 comments
Open

x/tools/gopls: provide quickfix for composite literals with unkeyed fields #53062

hyangah opened this issue May 25, 2022 · 3 comments
Labels
FeatureRequest gopls/analysis gopls/refactoring gopls Tools
Milestone

Comments

@hyangah
Copy link
Contributor

@hyangah hyangah commented May 25, 2022

gopls provides diagnostics about composite literals with unkeyed fields.
It will be convenient if the diagnostic is accompanied with the quickfix.

Screen Shot 2022-05-24 at 8 22 58 PM

@hyangah hyangah added FeatureRequest gopls/analysis labels May 25, 2022
@gopherbot gopherbot added Tools gopls labels May 25, 2022
@gopherbot gopherbot added this to the Unreleased milestone May 25, 2022
@hyangah hyangah removed this from the Unreleased milestone May 26, 2022
@hyangah hyangah added this to the gopls/later milestone May 26, 2022
@hyangah
Copy link
Contributor Author

@hyangah hyangah commented May 26, 2022

@suzmue @jamalc Can you take a look if this can be implemented while investigating on a related feature (inLayHints)?

@findleyr findleyr added the gopls/refactoring label May 26, 2022
@findleyr
Copy link
Contributor

@findleyr findleyr commented May 26, 2022

I think this can be an inLayHint suggestion (by providing InlayHint textedits), but it would be good to have available as a quickfix as well.

@gopherbot
Copy link

@gopherbot gopherbot commented Jun 27, 2022

Change https://go.dev/cl/414674 mentions this issue: go/analysis: add suggested fix for unkeyed composite literals

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
FeatureRequest gopls/analysis gopls/refactoring gopls Tools
Projects
None yet
Development

No branches or pull requests

3 participants