diff --git a/generator.js b/generator.js index 0226b98..695ab6f 100644 --- a/generator.js +++ b/generator.js @@ -510,6 +510,13 @@ object.Mixin('AsyncGeneratorProtoMixin', 'soft', { return [] }) return state }, + flat: async function*(){ + for await(var e of this){ + if(e instanceof Array){ + yield* e + } else { + yield e }}}, + concat: async function*(other){ yield* this yield* other },