Skip to content

x/tools/gopls: track uses with fillreturns adding error returns #47637

Open
@stamblerre

Description

@stamblerre

Fillreturns uses any in-scope variables when they match the type, but this doesn't work well with error returns.
An example of this is found in https://www.youtube.com/watch?v=6r08zGi38Tk around the 11:20 mark. The err return variable has already been used in an earlier return statement, but we still return it again below. It would be nice to check that it had already been used and use nil instead.

Metadata

Metadata

Assignees

No one assigned

    Labels

    FeatureRequestIssues asking for a new feature that does not need a proposal.ToolsThis label describes issues relating to any tools in the x/tools repository.goplsIssues related to the Go language server, gopls.

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions