You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardexpand all lines: graalpython/com.oracle.graal.python.pegparser/src/com/oracle/graal/python/pegparser/scope/ScopeEnvironment.java
Copy file name to clipboardexpand all lines: graalpython/com.oracle.graal.python.test.integration/src/com/oracle/graal/python/test/integration/generator/GeneratorTests.java
+116-1
Original file line number
Diff line number
Diff line change
@@ -72,7 +72,7 @@ public void desugared() {
72
72
}
73
73
74
74
@Test
75
-
publicvoidtestYieldFrom() {
75
+
publicvoidtestYieldFromSimple() {
76
76
Stringsource = "def gen1():\n" +
77
77
" yield 1\n" +
78
78
" yield 2\n" +
@@ -83,4 +83,119 @@ public void testYieldFrom() {
83
83
"print(list(gen2()))\n";
84
84
assertPrints("[1, 2]\n", source);
85
85
}
86
+
87
+
@Test
88
+
publicvoidtestYieldFromIterable() {
89
+
// yield from should extract an iterator from a non-generator argument
Copy file name to clipboardexpand all lines: graalpython/com.oracle.graal.python.test.integration/src/com/oracle/graal/python/test/integration/grammar/ClassTests.java
+17
Original file line number
Diff line number
Diff line change
@@ -205,4 +205,21 @@ public void multipleInheritance() {
Copy file name to clipboardexpand all lines: graalpython/com.oracle.graal.python.test.integration/src/com/oracle/graal/python/test/integration/grammar/TryTests.java
+45
Original file line number
Diff line number
Diff line change
@@ -290,4 +290,49 @@ public void testExceptionState6() {
0 commit comments