www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.bugs - [Issue 15983] New: [REG 2.071] Symbol visibility in derived classes


          Issue ID: 15983
           Summary: [REG 2.071] Symbol visibility in derived classes
           Product: D
           Version: D2
          Hardware: All
                OS: All
            Status: NEW
          Severity: regression
          Priority: P1
         Component: dmd
          Assignee: nobody puremagic.com
          Reporter: renezwanenburg gmail.com

This is probably the same issue as 15897, only no circular imports are

module a;

class Base
  private alias Something = int;

void foo(T : Base)(T t)
  T.Something something;

module b;
import a;

class Derived : Base {}

void main()
  foo(new Derived());

This fails to compile with the message
a.d(10): Error: no property 'Something' for type 'b.Derived'.

In this case the fix is easy enough: just use Base.Something in foo(). But my
actual code involves a templated base class and template mixin which make that

May 02 2016