]> granicus.if.org Git - clang/commitdiff
Driver: ArgList doesn't depend on Options.h anymore.
authorDaniel Dunbar <daniel@zuster.org>
Thu, 19 Nov 2009 04:25:22 +0000 (04:25 +0000)
committerDaniel Dunbar <daniel@zuster.org>
Thu, 19 Nov 2009 04:25:22 +0000 (04:25 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@89313 91177308-0d34-0410-b5e6-96231b3b80d8

include/clang/Driver/ArgList.h
lib/Driver/Compilation.cpp
lib/Driver/Driver.cpp
lib/Driver/ToolChains.cpp
lib/Driver/Tools.cpp
tools/driver/driver.cpp

index 281a89b448693fe5d32d97c810cb0cda949e27d3..5263108d1a6d3eca66f38f18a60ee2c4996a20c2 100644 (file)
@@ -11,7 +11,6 @@
 #define CLANG_DRIVER_ARGLIST_H_
 
 #include "clang/Driver/OptSpecifier.h"
-#include "clang/Driver/Options.h"
 #include "clang/Driver/Util.h"
 #include "llvm/ADT/SmallVector.h"
 #include "llvm/ADT/StringRef.h"
index c12f5aa88195a5038840752b970a919842285f10..ffa627ad2810863d2cb20b624a693414ceaf31cb 100644 (file)
@@ -13,6 +13,7 @@
 #include "clang/Driver/ArgList.h"
 #include "clang/Driver/Driver.h"
 #include "clang/Driver/DriverDiagnostic.h"
+#include "clang/Driver/Options.h"
 #include "clang/Driver/ToolChain.h"
 
 #include "llvm/Support/raw_ostream.h"
index e0cc9a72753af3031c6a0ea6ae118811b34031a7..bf9244f28286407fcfd9498a50f623c2ae91cbf6 100644 (file)
@@ -341,8 +341,8 @@ void Driver::PrintHelp(bool ShowHidden) const {
   // Render help text into (option, help) pairs.
   std::vector< std::pair<std::string, const char*> > OptionHelp;
 
-  for (unsigned i = options::OPT_INPUT, e = options::LastOption; i != e; ++i) {
-    options::ID Id = (options::ID) i;
+  for (unsigned i = 0, e = getOpts().getNumOptions(); i != e; ++i) {
+    options::ID Id = (options::ID) (i + 1);
     if (const char *Text = getOpts().getOptionHelpText(Id))
       OptionHelp.push_back(std::make_pair(getOptionHelpName(getOpts(), Id),
                                           Text));
index a9a2d0fbc3c5f6e7a25e28311eb69f3457a1130b..af639523f1d7e786fed2167b775bc9d8c2a8b3c4 100644 (file)
@@ -16,6 +16,7 @@
 #include "clang/Driver/HostInfo.h"
 #include "clang/Driver/OptTable.h"
 #include "clang/Driver/Option.h"
+#include "clang/Driver/Options.h"
 
 #include "llvm/ADT/StringExtras.h"
 #include "llvm/Support/ErrorHandling.h"
index 15e5f3fffded6d84a07d8a79d8c8fa2549ea5aee..e7dcc20883eadfd625ea7592ba2735cb2679553b 100644 (file)
@@ -18,6 +18,7 @@
 #include "clang/Driver/Job.h"
 #include "clang/Driver/HostInfo.h"
 #include "clang/Driver/Option.h"
+#include "clang/Driver/Options.h"
 #include "clang/Driver/ToolChain.h"
 #include "clang/Driver/Util.h"
 
index fb7c6cc7b03254a89851d776cd1197b5531a2791..43dd36963c6d05e6178384d657b8dd11a39797be 100644 (file)
@@ -15,7 +15,6 @@
 #include "clang/Driver/Compilation.h"
 #include "clang/Driver/Driver.h"
 #include "clang/Driver/Option.h"
-#include "clang/Driver/Options.h"
 
 #include "llvm/ADT/SmallString.h"
 #include "llvm/ADT/OwningPtr.h"