Skip to content

Instantly share code, notes, and snippets.

@jetaggart
Last active January 31, 2019 00:32
Show Gist options
  • Save jetaggart/0568dfd7d82f468abeb3c0d2ee5fc38a to your computer and use it in GitHub Desktop.
Save jetaggart/0568dfd7d82f468abeb3c0d2ee5fc38a to your computer and use it in GitHub Desktop.
void main() {
wrappingGenerator().listen((i) => print(i));
}
Stream<int> wrappingGenerator() async* {
nestedGenerator().listen((i) async* { yield i; });
}
Stream<int> nestedGenerator() async* {
yield 1;
yield 2;
yield 3;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment