Skip to content

caret jumps from the second-last character of variable, with type inlay hints #2888

@tigregalis

Description

@tigregalis

Apologies for the messy issue title. Not sure how to phrase it. Example below applies to VS Code.

type-inlay-hint-issue

With type inlay hints, when moving the caret, it jumps from between the second-last and last characters ([len-1, len]) of the variable name to the end of the inlay hint. That is, the caret never falls after the end of the variable name on the last character ([len, len+1]).

This is unintuitive. It would be more appropriate to have the type inlay hint "occupy" the whitespace afterwards instead.

The parameter inlay hint appears to behave intuitively.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions