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

Replace simple if let constructs with Option::map #79817

Merged
merged 1 commit into from
Dec 8, 2020

Conversation

LingMan
Copy link
Contributor

@LingMan LingMan commented Dec 8, 2020

Replaces a few constructs of the form

if let Some(x) = var {
    Some(...)
} else {
    None
}

with calls to Option::map.

@rustbot modify labels +C-cleanup +T-compiler

Replaces a few constructs of the form

if let Some(x) = var {
    Some(...)
} else {
    None
}

with calls to Option::map.
@rustbot rustbot added C-cleanup Category: PRs that clean code up or issues documenting cleanup. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. labels Dec 8, 2020
@rust-highfive
Copy link
Collaborator

r? @ecstatic-morse

(rust-highfive has picked a reviewer for you, use r? to override)

@rust-highfive rust-highfive added the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label Dec 8, 2020
@lcnr
Copy link
Contributor

lcnr commented Dec 8, 2020

r? @lcnr

@bors r+ rollup

@bors
Copy link
Contributor

bors commented Dec 8, 2020

📌 Commit af9402a has been approved by lcnr

@rust-highfive rust-highfive assigned lcnr and unassigned ecstatic-morse Dec 8, 2020
@bors bors added S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Dec 8, 2020
@bors
Copy link
Contributor

bors commented Dec 8, 2020

⌛ Testing commit af9402a with merge 5e6e1e3...

@bors
Copy link
Contributor

bors commented Dec 8, 2020

☀️ Test successful - checks-actions
Approved by: lcnr
Pushing 5e6e1e3 to master...

@bors bors added the merged-by-bors This PR was explicitly merged by bors. label Dec 8, 2020
@bors bors merged commit 5e6e1e3 into rust-lang:master Dec 8, 2020
@rustbot rustbot added this to the 1.50.0 milestone Dec 8, 2020
@LingMan LingMan deleted the if_map branch December 8, 2020 17:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
C-cleanup Category: PRs that clean code up or issues documenting cleanup. merged-by-bors This PR was explicitly merged by bors. S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

6 participants