Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[503] Project-wide renaming #1877

Merged
merged 5 commits into from
Jan 10, 2025
Merged

[503] Project-wide renaming #1877

merged 5 commits into from
Jan 10, 2025

Conversation

voodoos
Copy link
Collaborator

@voodoos voodoos commented Dec 17, 2024

This PR adds initial support for project-wide Renaming:

  • When indexing, declarations which are linked together are aggregated in an union-find structure.
  • When calling occurrences with the new scope Renaming, Merlin will return all the usages of the definition corresponding to the selected identifier, all the declarations/definitions linked to that definition and all the usages of all these definitions.

This PR is based on #1857

Todo

  • Add tests

@voodoos voodoos marked this pull request as ready for review December 20, 2024 16:30
voodoos added a commit to voodoos/merlin that referenced this pull request Dec 20, 2024
src/analysis/occurrences.ml Outdated Show resolved Hide resolved
src/index-format/union_find.ml Outdated Show resolved Hide resolved
@voodoos voodoos added this to the 5.4-503 milestone Jan 8, 2025
voodoos added a commit to voodoos/merlin that referenced this pull request Jan 9, 2025
@voodoos voodoos merged commit 9dcffb9 into ocaml:main Jan 10, 2025
4 of 5 checks passed
voodoos added a commit to voodoos/opam-repository that referenced this pull request Jan 10, 2025
CHANGES:

Fri Jan 10 17:55:42 CET 2025

  + merlin binary
    - Support for OCaml 5.3
    - Use new 5.3 features to improve locate behavior in some cases. Merlin no
      longer confuses uids from interfaces and implementations. (ocaml/merlin#1857)
    - Perform less merges in the indexer (ocaml/merlin#1881)
    - Add initial support for project-wide renaming: occurrences can now return
      all usages of all related definitions. (ocaml/merlin#1877)
  + vim plugin
    - Added support for search-by-type (ocaml/merlin#1846)
      This is exposed through the existing `:MerlinSearch` command, that
      switches between search-by-type and polarity search depending on the
      first character of the query.
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.

3 participants