Commit e5146422 authored by Marius Wachtler's avatar Marius Wachtler

allow generator to return non None values

we create quite strange lambda cfg nodes but it should be fine I guess
parent 741f69f0
......@@ -107,7 +107,6 @@ void generatorEntry(BoxedGenerator* g) {
auto r = callCLFunc<ExceptionStyle::CXX, NOT_REWRITABLE>(func->md, nullptr, func->md->numReceivedArgs(),
func->closure, g, func->globals, g->arg1, g->arg2,
g->arg3, args);
assert(r == None);
Py_DECREF(r);
} catch (ExcInfo e) {
// unhandled exception: propagate the exception to the caller
......
# expected: reffail
def G1(i=0):
while True:
yield i
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment