Skip to content

Update of language/async_star/throw_in_catch_test to correct async* semantics caused dart2js failure. #48749

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
mkustermann opened this issue Apr 6, 2022 · 1 comment
Labels
area-web-js Issues related to JavaScript support for Dart Web, including DDC, dart2js, and JS interop. type-bug Incorrect behavior (everything from a crash to more subtle misbehavior) web-dart2js

Comments

@mkustermann
Copy link
Member

After changing language/async_star/throw_in_catch_test in cl/239421 to the semantics we want for async* (verified with lrn@), dart2js fails this test.

/cc @rakudrama

@mkustermann mkustermann added type-bug Incorrect behavior (everything from a crash to more subtle misbehavior) area-web-js Issues related to JavaScript support for Dart Web, including DDC, dart2js, and JS interop. labels Apr 6, 2022
@mkustermann
Copy link
Member Author

Small reproduction that demonstrates the issue

foo() async* {
  print('a');
  yield 1;
  print('should not print (our listener cancelled)');
}

main() async {
  var subscription;
  subscription = foo().listen((event) {
    subscription.cancel();
  });
}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area-web-js Issues related to JavaScript support for Dart Web, including DDC, dart2js, and JS interop. type-bug Incorrect behavior (everything from a crash to more subtle misbehavior) web-dart2js
Projects
None yet
Development

No branches or pull requests

2 participants