imports - 2 years later

Ant Ant_member at pathlink.com
Thu Mar 9 09:40:15 PST 2006


In article <dupl7t$mqk$1 at digitaldaemon.com>, Lars Ivar Igesund says...
>
>Derek Parnell wrote:
>
>> On Fri, 10 Mar 2006 00:28:50 +1100, Ant <Ant_member at pathlink.com> wrote:
>> 
>>> In article <ops5425bcg23k2f5 at nrage.netwin.co.nz>, Regan Heath says...
>>>>
>>>> I believe Walter discourages the use of import inside a class and I
>>>> believe your use of them is the reason for the problem.
>>>
>>> I need to make a joke and a note:
>>>
>>> so we have a ternary logic:
>>> - import in module: true
>>> - import in function: false
>>> - import in class: maybe
>> 
>> Why would one think of importing stuff into a class? I don't get it. Are
>> you trying to make the imported stuff 'local' to the class members and
>> nothing else?
>> 
>
>Because when Ant first wrote DUI, class local imports were a workaround to
>much bigger import problems than those we meet today.

yes, and more,
I'm going to use the import symbols inside the class body,
what makes no sence is to have the import at the module level - see there
is always another way to look at things.

and more,
If I have multiple classes in the same module maybe it makes sence to 
import the specific modules to the right class.

Anyway, this needs to be reviewd.

And import in classes should either be corrected (please) or made illegal(no).

Ant






More information about the Digitalmars-d-bugs mailing list