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

Fix covered-switch-default warnings in RustWrapper #39063

Merged
merged 1 commit into from
Jan 15, 2017

Conversation

ruuda
Copy link
Contributor

@ruuda ruuda commented Jan 14, 2017

These switch statements cover all possible values, so the default case is dead code (it contains an llvm_unreachable anyway), triggering a -Wcovered-switch-default warning that pollutes the build output. Moving the unreachable after the switch resolves these warnings.

r? @rkruppe

These switch statements cover all possible values, so the default case
is dead code (it contains an llvm_unreachable anyway), triggering a
-Wcovered-switch-default warning. Moving the unreachable after the
switch resolves these warnings. This keeps the build output clean.
Copy link
Contributor

@hanna-kruppe hanna-kruppe left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, thanks!

@alexcrichton
Copy link
Member

@bors: r+

@bors
Copy link
Contributor

bors commented Jan 14, 2017

📌 Commit 004f18d has been approved by alexcrichton

@bors
Copy link
Contributor

bors commented Jan 15, 2017

⌛ Testing commit 004f18d with merge c21f73e...

bors added a commit that referenced this pull request Jan 15, 2017
Fix covered-switch-default warnings in RustWrapper

These switch statements cover all possible values, so the default case is dead code (it contains an `llvm_unreachable anyway`), triggering a `-Wcovered-switch-default` warning that pollutes the build output. Moving the unreachable after the switch resolves these warnings.

r? @rkruppe
@bors
Copy link
Contributor

bors commented Jan 15, 2017

☀️ Test successful - status-appveyor, status-travis
Approved by: alexcrichton
Pushing c21f73e to master...

@bors bors merged commit 004f18d into rust-lang:master Jan 15, 2017
@ruuda ruuda deleted the covered-switch branch January 15, 2017 17:51
kennytm added a commit to kennytm/rust that referenced this pull request Aug 8, 2017
bors added a commit that referenced this pull request Aug 9, 2017
Fix covered-switch-default warnings in PassWrapper

(See #39063 for explanation)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants