-
Notifications
You must be signed in to change notification settings - Fork 1.6k
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
Fix suggestion to add unneeded space in manual_async
#6294
Fix suggestion to add unneeded space in manual_async
#6294
Conversation
r? @Manishearth (rust_highfive has picked a reviewer for you, use r? to override) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
code seems fine, would like it to be a common function
clippy_lints/src/manual_async_fn.rs
Outdated
if let Some(ret_pos) = header_snip.rfind("->"); | ||
if let Some(ret_pos) = header_snip.rfind("->").map(|rpos| { | ||
let mut rpos = rpos; | ||
let chars: Vec<char> = header_snip.chars().collect(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
could you refactor this into something for utils
so #6247 can also use it
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for your review! I refactored this.
ef946b7
to
b7892c6
Compare
@bors r+ i was wondering what a good name for the function would be but this is as good as any |
📌 Commit b7892c6 has been approved by |
☀️ Test successful - checks-action_dev_test, checks-action_remark_test, checks-action_test |
Fix a same case as #6247
changelog: Fix suggestion to add unneeded space in
manual_async