4 ms·
What? Exporting a type or field is an opt-in decision, you don't need a special package per type to do it. If the fear is that other types or functions in the
by sagichmal 7y ago
What? Exporting a type or field is an opt-in decision, you don't need a special package per type to do it.
If the fear is that other types or functions in the same package can access the unexported fields, that's unavoidable, making a new package per type doesn't reduce the risk.