On Sunday, 21 October 2018 at 03:17:23 UTC, 12345swordy wrote:
So that classes can share some of their variables but not others in a module.

IE.

class A
{
internal int A; //This is shared in the module
private int B; // But not this.
}

No need to reintroduce the "Friend" feature from cpp.

As just said by others, if you need it probably your module is too big and you have to split.

Moreover: you're the author of the module so you're supposed to know how it works and which members you should call or not. Anyway since they're private you can name them in particular way to remember yourself not to use them eg: int internal_A;

Andrea

Reply via email to