We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 953c23b commit 80f638fCopy full SHA for 80f638f
2 files changed
tests/misc/recursive_iternext.py
@@ -0,0 +1,33 @@
1
+# This tests that recursion with iternext doesn't lead to segfault.
2
+
3
+try:
4
+ x = (1, 2)
5
+ for i in range(1000):
6
+ x = enumerate(x)
7
+ tuple(x)
8
+except RuntimeError:
9
+ print("RuntimeError")
10
11
12
13
14
+ x = filter(None, x)
15
16
17
18
19
20
21
22
+ x = map(max, x, ())
23
24
25
26
27
28
29
30
+ x = zip(x)
31
32
33
tests/misc/recursive_iternext.py.exp
@@ -0,0 +1,4 @@
+RuntimeError
0 commit comments