From: Miss Islington (bot) <31488909+miss-islington@users.noreply.github.com> Date: Fri, 19 Jul 2024 11:50:34 +0000 (+0200) Subject: [3.13] gh-121657: Additional `yield from` error test using lambda (GH-121722) (GH... X-Git-Tag: v3.13.0rc1~98 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=58a84e58f45cb656b756cf007f629d868e119d8b;p=thirdparty%2FPython%2Fcpython.git [3.13] gh-121657: Additional `yield from` error test using lambda (GH-121722) (GH-121961) (cherry picked from commit 1056f2bc208bdfe562c79d2a5098723c50ae9c23) Co-authored-by: Gregor <36135323+gege-hoho@users.noreply.github.com> --- diff --git a/Lib/test/test_generators.py b/Lib/test/test_generators.py index fd3e88f11858..6203db8939aa 100644 --- a/Lib/test/test_generators.py +++ b/Lib/test/test_generators.py @@ -2247,6 +2247,11 @@ Traceback (most recent call last): ... SyntaxError: 'yield' outside function +>>> f=lambda: (yield from (1,2)), (yield from (3,4)) +Traceback (most recent call last): + ... +SyntaxError: 'yield from' outside function + >>> yield from [1,2] Traceback (most recent call last): ...