Is there a way to achieve this:
----
module foo;
{
import bar;
void fun1(){bar.barfun();}
void fun2(bar.BarType a){}
}
// now bar is not in scope anymore.
void fun3(){}
This would reduce name clashes conflicts, ease refactorings and in general make code a bit cleaner.
Related question:
Why isn't the following allowed:
----
void fun(){
// code without version=A
version=A;
// code with version=A
vesion(none):
//code versioned out
}
I understand the grammar doesn't allow it, but what's the rationale, and can it be fixed?