other python ideas

Ben Wolfson rumjuggler at cryptarchy.org
Tue May 30 20:13:57 EDT 2000


On Tue, 30 May 2000 13:06:15 -0400, Peter Gavin <gavin at coaps.fsu.edu>
wrote:

>Laurent POINTAL wrote:
>> 
>> In our modules, we use the following syntax to avoid publication of
>> imported symbols (copied from... I dont remember which Python source):
>> 
>> import string
>> _string = string
>> del string
>> 
>> And we always prefix string operation functions by _string.
>> 
>
>This looks like a good idea.  Wouldn't it be useful to be able to do it
>in one step?
>It shouldn't be too hard to add a syntax similar to:
>
>import string as _string
>
>That would eliminate the need for _string = string; del string.

Vyper has that construction.

-- 
Barnabas T. Rumjuggler

On the window that I looked through there was, instead of a
crossed-out cigarette, a crossed-out bottle. What a good idea to cross
things out on windows, I thought. What a convenience.
 -- Russell Hoban, _The Medusa Frequency_



More information about the Python-list mailing list