How do I create a module-local immutable class object?

Andrej Mitrovic andrej.mitrovich at gmail.com
Sat Sep 10 15:53:21 PDT 2011


foo\bar.d:
module foo.bar;
private class Foo {}

main.d:
import foo.bar : Foo;
void main()
{
	auto foo = new Foo();
}

This should be a compile error, no?


More information about the Digitalmars-d-learn mailing list