A more granular visibility system in Rust: https://github.com/rust-lang/rust/issues/32409 (their RFC process is remarkably effective for productive discussion)
miniblog.
Related Posts
Should code completion offer private methods/fields?
If the user chooses a private method, you can offer a quickfix to change its visibility. It's clutter though.
I frequently find myself wanting fields that I haven't exposed yet, and frustrated that the IDE hides them.
I feel like increasing visibility of a function/type should require more verbosity. I don't know of any PL that follows this design principle for >2 levels though.
Ordered by verbosity:
public, private, protected
, pub, pub(crate)
Has any PL solved this?
What takes more keystrokes in a language? Public visibility (Rust), private visibility (Python, Clojure) or neither (Go). Defaults matter.