On Saturday, 19 May 2018 at 04:01:18 UTC, KingJoffrey wrote:
Mmm.. that brings me back to the idea of sealed at the class level again.

class A
{
   private int x;
private(this) int y; // imagine if you have lots of private variables. // this could become pretty anoying - and kinda redundant.
}

All attributes in D work the same way. You can write things like:

class A
{
  @Jsonize:
  private:
  int a;
  string b;

  protected
  {
    long c;
  }

  @safe:
  void privateSafeFunction() {}
  void otherPrivateSafeFunction() {}
}

Perhaps you should learn more about the language before proposing specific changes?

Reply via email to