Skip to content

this-function parameter can be renamed #9037

@sandersn

Description

@sandersn
function(this/**/: string, x: number) {
  return this.length;
}

Now try to rename or find all references at /**/.

Expected: Message "You cannot rename this element".

Actual: Rename just the parameter, nothing in the body. Find all references just finds one reference, the definition.

Probably this needs to be classified as ThisKeyword by the parser as long as that doesn't break anything else.

Metadata

Metadata

Assignees

No one assigned

    Labels

    BugA bug in TypeScriptFixedA PR has been merged for this issue

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions