[Python-Dev] Re: from ... import * ([Python-checkins] CVS: python/dist/src/Python
Tue, 30 Jan 2001 23:35:58 -0500 (EST)
>>>>> "MAL" == M -A Lemburg <firstname.lastname@example.org> writes:
>> Modified Files: compile.c Log Message: Enforce two illegal import
>> statements that were outlawed in the reference manual but not
>> checked: Names bound by import statemants may not occur in global
>> statements in the same scope. The from ... import * form may only
>> occur in a module scope.
>> I guess these changes could break code, but the reference manual
>> warned about them.
MAL> Jeremy, your code breaks all uses of "from package import
MAL> submodule" inside packages.
MAL> Try distutils for example or setup.py....
Quite aside from whether the changes should be preserved, I don't see
how "from package import submodule" is affected. I ran setup.py
without any problem; I wouldn't have been able to build Python
otherwise. I wrote some simple test cases and didn't have any trouble
with the form you describe.
Can you provide a concrete example? It may be that something other
than the changes mentioned above that is causing you problems.