Private static inheritance

David Ferenczi raggae at ferenczi.net
Sun Sep 23 22:06:10 PDT 2007


Kirk McDonald wrote:

> David Ferenczi wrote:
> [snip]
>> static private import testAA: AA;
>> static private import std.cstream: dout;
> [snip]
> 
> Though this has nothing to do with your question, this is not valid
> code. A selective import cannot also be a static import. When you say:
> 
> import std.stdio : writefln;
> 
> Then the only symbol which is inserted into the module's namespace is
> 'writefln' (and not 'std'). Putting 'static' in front of this import
> causes the compiler to give this error:
> 
> test.d(1): static import std cannot have an import bind list

Hi Kirk,

tnank you for pointing this out. I will correct it. Nevertheless the code
compiles with dmd-1.20 under linux.

Regards,
David 



More information about the Digitalmars-d-learn mailing list