Uh oh!
There was an error while loading. Please reload this page.
Suggest let for assignment, and some code refactor - #101908
Conversation
rust-highfive
commented
Sep 16, 2022
r? @oli-obk (rust-highfive has picked a reviewer for you, use r? to override) |
Uh oh!
There was an error while loading. Please reload this page.
This comment has been minimized.
This comment has been minimized.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
By the way, |
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
estebank
commented
Sep 19, 2022
We should, but better to do it as part of its own PR. |
bors
commented
Sep 29, 2022
☔ The latest upstream changes (presumably #102450) made this pull request unmergeable. Please resolve the merge conflicts. |
99a33b3 to
7d201c9Comparechenyukang
commented
Oct 14, 2022
r? @estebank |
bors
commented
Oct 20, 2022
☔ The latest upstream changes (presumably #103185) made this pull request unmergeable. Please resolve the merge conflicts. |
estebank
left a comment
There was a problem hiding this comment.
r=me after rebasing (ping me and I'll approve)
There was a problem hiding this comment.
This can now be written as follows
| let has_eq = matches!(sm.span_to_snippet(eq_span),Ok(ref snippet)if snippet == "="); | |
| if has_eq { | |
| ifletOk(ref snippet) = sm.span_to_snippet(eq_span) && snippet == "="{ |
There was a problem hiding this comment.
Is this check to protect against macros or something else?
There was a problem hiding this comment.
Ah, yes. Saw the dbg!(binding) case in the test. Hacky, but makes sense!
There was a problem hiding this comment.
emm, I will add a comment for this.
This comment has been minimized.
This comment has been minimized.
| break; | ||
| } | ||
| } | ||
| let closing_span = sm.span_look_ahead(span, Some("}"), Some(50)); |
There was a problem hiding this comment.
Since the next_point bug is fixed, this is changed from 100 to 50 😂
chenyukang
commented
Oct 21, 2022
r? @estebank |
estebank
commented
Oct 21, 2022
@bors r+ |
bors
commented
Oct 21, 2022
Suggest let for assignment, and some code refactor Fixesrust-lang#101880
Rollup of 6 pull requests Successful merges: - rust-lang#101293 (Recover when unclosed char literal is parsed as a lifetime in some positions) - rust-lang#101908 (Suggest let for assignment, and some code refactor) - rust-lang#103192 (rustdoc: Eliminate uses of `EarlyDocLinkResolver::all_traits`) - rust-lang#103226 (Check `needs_infer` before `needs_drop` during HIR generator analysis) - rust-lang#103249 (resolve: Revert "Set effective visibilities for imports more precisely") - rust-lang#103305 (Move some tests to more reasonable places) Failed merges: r? `@ghost` `@rustbot` modify labels: rollup
Kaligule
commented
Oct 28, 2022
Thank you @chenyukang |
Fixes#101880