Skip to content
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

Code action to toggle async fn and impl Future #17010

Closed
ryo33 opened this issue Apr 4, 2024 · 0 comments · Fixed by #17258
Closed

Code action to toggle async fn and impl Future #17010

ryo33 opened this issue Apr 4, 2024 · 0 comments · Fixed by #17258
Labels
C-feature Category: feature request

Comments

@ryo33
Copy link

ryo33 commented Apr 4, 2024

It's better to have a code action that toggles a function or trait method between async fn method() -> Ret and fn method() -> impl Future<Output = Ret>. Conversion from async fn to impl Future should be lossless, but, of course, the opposite is not.

It's convenient in cases like:

@ryo33 ryo33 added the C-feature Category: feature request label Apr 4, 2024
@bors bors closed this as completed in b32f181 May 27, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
C-feature Category: feature request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant