Added zip, map, filter to future_bultins (#2171)
diff --git a/Modules/itertoolsmodule.c b/Modules/itertoolsmodule.c
index 8c3375a..a369dc9 100644
--- a/Modules/itertoolsmodule.c
+++ b/Modules/itertoolsmodule.c
@@ -2542,7 +2542,7 @@
ifilterobject *lz;
if (Py_Py3kWarningFlag &&
- PyErr_Warn(PyExc_DeprecationWarning,
+ PyErr_Warn(PyExc_DeprecationWarning,
"In 3.x, itertools.ifilter() was moved to builtin filter().") < 0)
return NULL;
@@ -2552,6 +2552,15 @@
if (!PyArg_UnpackTuple(args, "ifilter", 2, 2, &func, &seq))
return NULL;
+ if (func == Py_None) {
+ if (Py_Py3kWarningFlag &&
+ PyErr_Warn(PyExc_DeprecationWarning,
+ "ifilter with None as a first argument "
+ "is not supported in 3.x. Use a list "
+ "comprehension instead.") < 0)
+ return NULL;
+ }
+
/* Get iterator. */
it = PyObject_GetIter(seq);
if (it == NULL)
@@ -3602,7 +3611,7 @@
&izip_type,
&iziplongest_type,
&permutations_type,
- &product_type,
+ &product_type,
&repeat_type,
&groupby_type,
NULL