Q: Python 2.0 preliminary features?

Preston Landers prestonlanders at my-deja.com
Fri Oct 8 16:29:30 EDT 1999


Hello all,

I know there's been some casual discussion here about Python 2.x.  I'm
wondering if anyone would be willing to summarize a list of language
features generally desired or expected for Python 2.  I'm not really
asking about the implementation but the language itself; any
interesting changes ahead?

And just because I like to start flame wars, I'll go ahead and add my
own feature to the wishlist:  nested scopes / namespaces.  Is this a
pipe dream, or just too hard to implement given the internal structure
of Python (which I'm not really familiar with.)  Maybe I'm just going
about it all wrong, but it seems like much of my code would be cleaner
given arbitrarily nested scopes.  I've discussed this with people
before on c.l.python but never really got an explanation that made
sense (to me) for the way it is now.

By the way, is there a function equivilent to the following in the
standard Python module library?

def unquote(s):
    """Remove any enclosing quotes around a string."""
    if (s[:1] == "'" and s[-1:] == "'") or (s[:1] == '"' and s[-1:]
== '"'):
        return s[1:-1]
    else:
        return s

thanks,

--
|| Preston Landers <prestonlanders at my-deja.com> ||


Sent via Deja.com http://www.deja.com/
Before you buy.




More information about the Python-list mailing list