Method of another module is callable, even if they is private.
Andrej Mitrovic
andrej.mitrovich at gmail.com
Sat Oct 12 12:07:35 PDT 2013
On 10/12/13, Namespace <rswhite4 at googlemail.com> wrote:
> Bug or feature? :P
Has to be a bug. Reduced:
-----
module a;
import b;
void main()
{
auto s = S();
auto f = &s.f; // no error
f(); // no error
auto sf = &S.sf; // error
}
-----
-----
module b;
struct S
{
private void f() { }
private static void sf() { }
}
-----
More information about the Digitalmars-d-learn
mailing list