On Monday, 5 May 2014 at 13:33:13 UTC, Jonathan M Davis via Digitalmars-d wrote:
IIRC, it had something to do with member functions, but I'd have to go digging through the newsgroup archives for the details. In general though, I think that private symbols should be ignored by everything outside of the module unless we have a very good reason to do otherwise. Maybe they should still be visible for the purposes of reflection or some other case where seeing the symbols would be useful, but they should never conflict with anything outside
of the module without a really good reason.

This works now and must continue to work I believe:

// a.d;

mixin template TMPL()
{
    void foo() { z = 42; }
}

// b.d
import a;

private int z;

mixin TMPL!();

Reply via email to