erlang-ls / erlang_ls

The Erlang Language Server
https://erlang-ls.github.io/
Apache License 2.0
620 stars 136 forks source link

Makes 'find_references/2' faster #1460

Closed shuying2244 closed 5 months ago

shuying2244 commented 8 months ago

Fixed the way Kind equals record/record_def_field/define works in find_references/2, this uri_pois_to_locations(find_scoped_references_for_def(Uri, Poi)); is really too slow, now they can use find_references_for_id(Kind, Key); like a function.

plux commented 5 months ago

This PR should make find_references faster, without sacrificing correct behavior. https://github.com/erlang-ls/erlang_ls/pull/1476