llvmbot wrote:

<!--LLVM PR SUMMARY COMMENT-->

@llvm/pr-subscribers-clangir

Author: David Olsen (dkolsen-pgi)

<details>
<summary>Changes</summary>

Fix a compiler warning in `CIRGenConsumer::HandleTranslationUnit` in 
`clang/lib/CIR/FrontendAction/CIRGenAction.cpp`.  The warning was about a 
`default:` section in a switch statement that already covered all the values of 
an enum.  Delete the `default:` section.

---
Full diff: https://github.com/llvm/llvm-project/pull/118389.diff


1 Files Affected:

- (modified) clang/lib/CIR/FrontendAction/CIRGenAction.cpp (-3) 


``````````diff
diff --git a/clang/lib/CIR/FrontendAction/CIRGenAction.cpp 
b/clang/lib/CIR/FrontendAction/CIRGenAction.cpp
index 5a31e207081936..21b6bc56ed0503 100644
--- a/clang/lib/CIR/FrontendAction/CIRGenAction.cpp
+++ b/clang/lib/CIR/FrontendAction/CIRGenAction.cpp
@@ -66,9 +66,6 @@ class CIRGenConsumer : public clang::ASTConsumer {
         MlirModule->print(*OutputStream, Flags);
       }
       break;
-    default:
-      llvm_unreachable("NYI: CIRGenAction other than EmitCIR");
-      break;
     }
   }
 };

``````````

</details>


https://github.com/llvm/llvm-project/pull/118389
_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to