Can you publicly alias a private type?

Peter Alexander peter.alexander.au at gmail.com
Tue Jun 21 07:14:14 PDT 2011


Is the following legal D?

// module A
private class Foo;
public alias Foo Bar;

// module B
import A;
Bar b; // I can't use Foo, but can I use Bar?


I'm adding module level protection for types into DMD and wondering if 
this should be legal.





More information about the Digitalmars-d mailing list