Skip to content

Quick fix: match variable name in inlay hint #123

@robertoaloi

Description

@robertoaloi

Context

When the name of the variable passed to a function during an invocation differs from the name of the correspondent parameter as defined in the function signature, we present an inlay hint showing the parameter name.

Problem

In some cases the user may want to align those names, which are different only due to accidental complexity.

Solution

Provide a quick fix that allows the user to match the variable name with the parameter hint (or viceversa).
Ensure the quick-fix for the viceversa is not available for OTP/dependency modules.
The quick-fix can reuse the infrastructure from the rename refactoring to perform the actual rename and verify the operation is safe (i.e. there is not a variable with the same name in scope).

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions