Skip to content

feat: Hide private fields on hover depending on context#22464

Open
Veykril wants to merge 1 commit into
rust-lang:masterfrom
Veykril:push-rkuqmqwwmpoq
Open

feat: Hide private fields on hover depending on context#22464
Veykril wants to merge 1 commit into
rust-lang:masterfrom
Veykril:push-rkuqmqwwmpoq

Conversation

@Veykril
Copy link
Copy Markdown
Member

@Veykril Veykril commented May 26, 2026

Hides private fields as follows

Hover location Definition location Render private fields?
Workspace crate Workspace crate Yes
Workspace crate External/library crate No
External/library crate Same external/library crate Yes
External/library crate Different external/library crate No
Anywhere Same crate as definition Yes

@rustbot rustbot added the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label May 26, 2026
@Veykril Veykril force-pushed the push-rkuqmqwwmpoq branch from 44f1bcf to 2e29ddd Compare May 26, 2026 20:25
@ChayimFriedman2
Copy link
Copy Markdown
Contributor

FWIW I do find private fields useful but as long as it's configurable I don't object (even if it's off by default).

@Veykril
Copy link
Copy Markdown
Member Author

Veykril commented May 29, 2026

I am curious about that thought, I think I was of the same opinion before but at this point I've kind of changed my mind. If its a private field in a dep I don't really see how it would be useful in the common case to see since it wont ever be possible for me to change that. And in the very rare case where it is interesting to then see one could always go to def. Hence this PR.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

S-waiting-on-review Status: Awaiting review from the assignee but also interested parties.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants