Georg Brandl <ge...@python.org> added the comment: >> Hmm, I wonder why lambda: (yield 1) alone doesn't give [1, None]. (That >> should also go into the test case.) > > Actually, I don't think the return value should even make it's way to > the list. Generator lambdas shouldn't have any return value IMO.
Yes, I think so too. I just wondered at the seemingly inconsistent behavior right now. >> Anyway, perhaps yield in lambdas should be forbidden. > > Probably too late now for 2.x and 3.x. Right. I'd say go for applying the patch. _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue4748> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com