3 ms·
> that modern Python does have workable co-routines I think its called 'yield from'. Not sure if I'm sold on the name, but surprised nobody has mentioned it
by penguindev 13y ago
> that modern Python does have workable co-routines
I think its called 'yield from'. Not sure if I'm sold on the name, but surprised nobody has mentioned it yet. From what I've seen, it looks really nice.
A comment on the post has an example of it:
def sync_and_read_bookmarks():
if (yield from sync_bookmarks()) > 0:
return (yield from read_bookmarks())