D - more or less power than C++?

Derek Parnell derek at psych.ward
Sat Mar 4 15:00:37 PST 2006


Walter,
I know you are a busy person and this might have been missed, so I repeat  
the question for you.

On Sat, 04 Mar 2006 15:02:35 +1100, Walter Bright
  <newshound at digitalmars.com> wrote:

> The private/protected stuff works like it does in C++.

  I'm not a C++ person so excuse my ignorance please, but are you saying
  that fully qualified references in C++ will override private/protected
  attributes? It does this in D.

  //--- foo.d --
  private void Foo() { }

  // --------------

  //--- test.d --
  import foo;
  void main()
  {
      foo.Foo(); // Compiles!
      Foo();  // Doesn't compile.
  }



-- 
Derek Parnell
Melbourne, Australia



More information about the Digitalmars-d mailing list