Skip to content

Fixing Rename Refactorings#1

Merged
przepompownia merged 4 commits intoprzepompownia:fix-will-renamefrom
phpactor:fix-will-rename-dan
Apr 14, 2024
Merged

Fixing Rename Refactorings#1
przepompownia merged 4 commits intoprzepompownia:fix-will-renamefrom
phpactor:fix-will-rename-dan

Conversation

@dantleech
Copy link

@dantleech dantleech commented Apr 13, 2024

  • Rename WorkspaceRenameEdits => WorkspaceOperations
  • Removes dead variable
  • Use merge to accumulate changes to the operations
  • Only convert once
  • Use IteratorAggregate instead of extending ArrayIterator

and finally makes the unit of operation the LocatedTextDocumentEdits and not the LocatedTextDocumentEditsMap

- Rename WorkspaceRenameEdits => WorkspaceOperations
- Removes dead variable
- Use `merge` to accumulate changes to the operations
- Only convert once
- Use IteratorAggregate instead of extending ArrayIterator
...i.e. LocatedTextDocuemntEdits maps to the LSP TextDocumentEdits
@przepompownia
Copy link
Owner

Looks fine at first glance but I get incomplete response (without text edits), for example

{
  documentChanges = { {
      kind = "rename",
      newUri = "file:///tmp/phpactor-dirty/lib/Name/Phpactor2.php",
      oldUri = "file:///tmp/phpactor-dirty/lib/Phpactor.php"
    } }
}

and haven't check why yet.

@dantleech
Copy link
Author

feel free to merge and change :)

@przepompownia przepompownia merged commit 0077bb6 into przepompownia:fix-will-rename Apr 14, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants