Skip to content

Cannot rename variable from use variable name #829

Closed

Description

@dantleech

When renaming from a use variable as follows:

return \Amp\call(function () use ($checkoutTask, $wo<>rkspace, $environment) {

we get the following error:

Error from Phpactor: Expected Variable or Parameter node, got "Microsoft\PhpParser\Node\UseVariableName

Note that I think currently variable renaming is limited to the current scope (probably the function) but in this case we also need to include the parent scope.

Activity

  1. camilledejoye commented on Oct 20, 2019

    @camilledejoye
    Contributor

    What is a "use variable" ?

  2. dantleech commented on Oct 20, 2019

    @dantleech
    CollaboratorAuthor

    Updated the description :)

  3. camilledejoye commented on Oct 20, 2019

    @camilledejoye
    Contributor

    I hate specific :D

  4. dantleech commented on Feb 22, 2020

    @dantleech
    CollaboratorAuthor

    Fixed in #888

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

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