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

"Add 'async' modifier" fix can change the wrong return type #31864

natebosch opened this Issue Jan 11, 2018 · 1 comment


None yet
2 participants

natebosch commented Jan 11, 2018

Here's a smallish repro:

import 'dart:async';

void takeFutureCallback(Future callback()) {}

void doStuff() => takeFutureCallback(() => await 1);

Put the cursor on the await and run the fix to add async. Result is:

Future doStuff() => takeFutureCallback(() async => await 1);

I expected

void doStuff() => takeFutureCallback(() async => await 1);

This comment has been minimized.

Show comment
Hide comment

@bwilkerson bwilkerson closed this Jan 30, 2018

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment