From: Pirama Arumuga Nainar Date: Mon, 9 Sep 2019 19:52:39 +0000 (+0000) Subject: [Driver] Handle default case in refactored addOpenMPRuntime X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=e6e28a0fa67117e4f5d4072c70c0e204812d896e;p=clang [Driver] Handle default case in refactored addOpenMPRuntime Summary: Appease failed builds (due to -Werror and -Wswitch) where OMPRT_Unknown is not handled in the switch statement (even though it's handled by the early exit). This fixes -Wswitch triggered by r371442. Reviewers: srhines, danalbert, jdoerfert Subscribers: guansong, cfe-commits Tags: #clang Differential Revision: https://reviews.llvm.org/D67364 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@371444 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/lib/Driver/ToolChains/CommonArgs.cpp b/lib/Driver/ToolChains/CommonArgs.cpp index e07b052487..ddf87a4183 100644 --- a/lib/Driver/ToolChains/CommonArgs.cpp +++ b/lib/Driver/ToolChains/CommonArgs.cpp @@ -525,6 +525,8 @@ bool tools::addOpenMPRuntime(ArgStringList &CmdArgs, const ToolChain &TC, case Driver::OMPRT_IOMP5: CmdArgs.push_back("-liomp5"); break; + case Driver::OMPRT_Unknown: + break; } if (ForceStaticHostRuntime)