rust-lang / rust-lang/rust-analyzer
Feature Request: A way to change the visibility of multiple items at once
Nobody has claimed this yet.
- Dominant language
- Rust
- Stars
- 16.9k
- Forks
- 2.2k
- Avg merge
- 1d 12h
- Merged PRs (30d)
- 72
Description
Quite a few times I work on a project and split it into modules/separate libraries and need to go in and manually add pub to the beginning of lots of fields of structs, it'd be nice if there was a way to either change the visibility of all fields in a struct at once, or all highlighted fields, or something similar.
I guess it'd also sometimes be useful to be able to bulk change the visibility of multiple functions or all functions in an impl block or something similar too, but that's come up for me less often.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reviewing rust-analyzer's existing visibility-related assists and code actions to determine where a bulk visibility change would fit. Define whether the first version targets struct fields, highlighted fields, functions, or impl blocks, and verify the chosen behavior with focused tests. Done means the selected group can be changed from private to public in one action.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- rust
- Domain
- developer-experience, tooling
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100