Skip to content

Commit

Permalink
Fix a warning: default label in switch which covers all enumeration v…
Browse files Browse the repository at this point in the history
…alues (NFC)
  • Loading branch information
joker-eph committed Nov 1, 2023
1 parent 5a71f7a commit ad1b7a4
Showing 1 changed file with 1 addition and 4 deletions.
5 changes: 1 addition & 4 deletions llvm/lib/Target/TargetMachineC.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -262,7 +262,7 @@ void LLVMSetTargetMachineGlobalISel(LLVMTargetMachineRef T, LLVMBool Enable) {

void LLVMSetTargetMachineGlobalISelAbort(LLVMTargetMachineRef T,
LLVMGlobalISelAbortMode Mode) {
GlobalISelAbortMode AM;
GlobalISelAbortMode AM = GlobalISelAbortMode::Enable;
switch (Mode) {
case LLVMGlobalISelAbortDisable:
AM = GlobalISelAbortMode::Disable;
Expand All @@ -273,9 +273,6 @@ void LLVMSetTargetMachineGlobalISelAbort(LLVMTargetMachineRef T,
case LLVMGlobalISelAbortDisableWithDiag:
AM = GlobalISelAbortMode::DisableWithDiag;
break;
default:
AM = GlobalISelAbortMode::Enable;
break;
}

unwrap(T)->setGlobalISelAbort(AM);
Expand Down

0 comments on commit ad1b7a4

Please sign in to comment.