[Python-Dev] PEP 328: import...as with relative import

Greg Ewing greg at cosc.canterbury.ac.nz
Thu May 6 20:39:12 EDT 2004


Guido:

> This doesn't strictly apply to "import ..abc as xyz", but it doesn't
> seem worth stretching the syntax when you can already do that using
> "from .. import abc as xyz".

I can see your point of view. It just seems a bit strange coming at
from the other direction -- if you can say 'import a.b as z' there
doesn't seem to be any good reason not to say 'import ..a.b as z'. I
can imagine people getting tripped up by this.

I guess you're right that it doesn't matter much either way.

Greg Ewing, Computer Science Dept, +--------------------------------------+
University of Canterbury,	   | A citizen of NewZealandCorp, a	  |
Christchurch, New Zealand	   | wholly-owned subsidiary of USA Inc.  |
greg at cosc.canterbury.ac.nz	   +--------------------------------------+



More information about the Python-Dev mailing list