[Python-Dev] PEP 3000 and iterators (original) (raw)
Lisandro Dalcin dalcinl at gmail.com
Sat Sep 10 00:15:01 CEST 2005
- Previous message: [Python-Dev] PEP 3000 and new style classes
- Next message: [Python-Dev] PEP 3000 and iterators
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
PEP 3000 says (http://www.python.org/peps/pep-3000.html) :
Core language
- Return iterators instead of lists where appropriate for atomic type methods (e.g. dict.keys(), dict.values(), dict.items(), etc.)
Built-in Namespace
- Make built-ins return an iterator where appropriate (e.g. range(), zip(), etc.)
- Relevant functions should consume iterators (e.g. min(), max()) To be removed:
- xrange(): use range() instead [1]
Any possibility to add one (or more) future statement to implicitly get this behavior? Any suggestion about naming?
-- Lisandro Dalcín
Centro Internacional de Métodos Computacionales en Ingeniería (CIMEC) Instituto de Desarrollo Tecnológico para la Industria Química (INTEC) Consejo Nacional de Investigaciones Científicas y Técnicas (CONICET) PTLC - Güemes 3450, (3000) Santa Fe, Argentina Tel/Fax: +54-(0)342-451.1594
- Previous message: [Python-Dev] PEP 3000 and new style classes
- Next message: [Python-Dev] PEP 3000 and iterators
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]