Closed tsuf239 closed 1 month ago
Thanks for opening this pull request! :tada: Please consult the contributing guidelines for details on how to contribute to this project. If you need any assistence, don't hesitate to ping the relevant owner over Discord.
Topic | Owner |
---|---|
Wing SDK and utility APIs | @chriscbr |
Wing Console | @ainvoner , @skyrpex , @polamoros |
JSON, structs, primitives and collections | @hasanaburayyan |
Platforms and plugins | @hasanaburayyan |
Frontend resources (website, react, etc) | @tsuf239 |
Language design | @chriscbr |
VSCode extension and language server | @markmcculloh |
Compiler architecture, inflights, lifting | @yoav-steinberg |
Wing Testing Framework | @tsuf239 |
Wing CLI | @markmcculloh |
Build system, dev environment, releases | @markmcculloh |
Library Ecosystem | @chriscbr |
Documentation | @hasanaburayyan |
SDK test suite | @tsuf239 |
Examples | @hasanaburayyan |
Wing Playground | @eladcon |
Console preview environment is available at https://wing-console-pr-6461.fly.dev :rocket:
Please include a detailed description with any important implementation notes
Thanks for contributing, @tsuf239! This PR will now be added to the merge queue, or immediately merged if tsuf/rename-refactor
is up-to-date with main
and the queue is empty.
Congrats! :rocket: This was released in Wing 0.73.46.
Checklist
fixes: #4596 https://www.loom.com/share/234a65f04ecb471b84621aa0cf27f66c
Created a new
rename_visitor
that has a list of symbol declarations and the references to them. it adds a symbol either as a reference or as a declaration during the visit. when executingcreate_text_edits
it chooses the symbol declaration and references the position belongs to and creates textEdits with the new_text passed by the LSP. I also updated theget_ranges
method to get all ranges in a certain line (and not only the first one)Currently, the renaming of class properties and namespaces is unsupported:
namespaces need a "customized" edit:
bring ex;
withexternals
as the new word won't becomebring externals;
butbring ex as externals;
.it seems like properties aren't declared/defined as the other symbols- so the current procedure isn't working for them.
[x] Title matches Winglang's style guide
[x] Description explains motivation and solution
[x] Tests added (always)
[ ] Docs updated (only required for features)
[ ] Added
pr/e2e-full
label if this feature requires end-to-end testingBy submitting this pull request, I confirm that my contribution is made under the terms of the Wing Cloud Contribution License.