]> granicus.if.org Git - clang/commitdiff
Fix build by using hasFlag instead of hasArg.
authorPeter Collingbourne <peter@pcc.me.uk>
Wed, 24 Feb 2016 22:03:06 +0000 (22:03 +0000)
committerPeter Collingbourne <peter@pcc.me.uk>
Wed, 24 Feb 2016 22:03:06 +0000 (22:03 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@261782 91177308-0d34-0410-b5e6-96231b3b80d8

lib/Driver/Tools.cpp

index 0206281ae2956002fc2f119a5d1f9b2cf2514fa1..0cb49afb72e2e083a24eab13af8b551e925ed488 100644 (file)
@@ -4270,8 +4270,8 @@ void Clang::ConstructJob(Compilation &C, const JobAction &JA,
     CmdArgs.push_back("-ffunction-sections");
   }
 
-  if (Args.hasArg(options::OPT_fwhole_program_vtables,
-                  options::OPT_fno_whole_program_vtables, false)) {
+  if (Args.hasFlag(options::OPT_fwhole_program_vtables,
+                   options::OPT_fno_whole_program_vtables, false)) {
     if (!D.isUsingLTO())
       D.Diag(diag::err_drv_argument_only_allowed_with)
           << "-fwhole-program-vtables"