Many questions

Robert Fraser fraserofthenight at gmail.com
Sun May 3 23:19:41 PDT 2009


Ellery Newcomer wrote:
> Nick Sabalausky wrote:
>> -------------------------------------
>> //File: foo/fooA.d
>> module foo.fooA;
>> class fooA {}
>>
>> //File: foo/fooB.d
>> module foo.fooB;
>> class fooB {}
>>
>> //File: foo/fooC.d
>> module foo.fooC;
>> class fooC {}
>>
>> //File: foo/all.d
>> module foo.all;
>> public import foo.fooA;
>> public import foo.fooB;
>> public import foo.fooC;
>>
>> //File: main.d
>> import foo.all;
>> void main() {...}
>> -------------------------------------
>>
>> This works fine and does exactly what you want.
>>
> 
> How well will this work if there is fairly tight coupling between these 
> three classes?

Not well at all :-). Technically, it should work the same as if they 
were in the same module, but compiler bugs dealing with forward 
references keep this from happening. I think a while back there was a 
version of LDC that pretty much fixed forward reference issues, but it 
introduced a bunch of regressions.



More information about the Digitalmars-d mailing list