[PATCH] D44508: Remove unnecessary include from Driver.cpp

Yuka Takahashi via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Fri Mar 16 01:32:45 PDT 2018


yamaguchi updated this revision to Diff 138671.
yamaguchi added a comment.

@marsupial Thanks for the commment, found a bug in my script and fixed. Now this patch removes only includes which are not used in each TU.


Repository:
  rL LLVM

https://reviews.llvm.org/D44508

Files:
  clang/lib/Driver/Driver.cpp
  clang/lib/Driver/DriverOptions.cpp
  clang/lib/Driver/Multilib.cpp
  clang/lib/Driver/Phases.cpp
  clang/lib/Driver/SanitizerArgs.cpp
  clang/lib/Driver/Types.cpp


Index: clang/lib/Driver/Types.cpp
===================================================================
--- clang/lib/Driver/Types.cpp
+++ clang/lib/Driver/Types.cpp
@@ -11,7 +11,6 @@
 #include "llvm/ADT/STLExtras.h"
 #include "llvm/ADT/StringSwitch.h"
 #include <cassert>
-#include <string.h>
 
 using namespace clang::driver;
 using namespace clang::driver::types;
Index: clang/lib/Driver/SanitizerArgs.cpp
===================================================================
--- clang/lib/Driver/SanitizerArgs.cpp
+++ clang/lib/Driver/SanitizerArgs.cpp
@@ -18,7 +18,6 @@
 #include "llvm/Support/FileSystem.h"
 #include "llvm/Support/Path.h"
 #include "llvm/Support/SpecialCaseList.h"
-#include <memory>
 
 using namespace clang;
 using namespace clang::SanitizerKind;
Index: clang/lib/Driver/Phases.cpp
===================================================================
--- clang/lib/Driver/Phases.cpp
+++ clang/lib/Driver/Phases.cpp
@@ -9,7 +9,6 @@
 
 #include "clang/Driver/Phases.h"
 #include "llvm/Support/ErrorHandling.h"
-#include <cassert>
 
 using namespace clang::driver;
 
Index: clang/lib/Driver/Multilib.cpp
===================================================================
--- clang/lib/Driver/Multilib.cpp
+++ clang/lib/Driver/Multilib.cpp
@@ -22,7 +22,6 @@
 #include "llvm/Support/YAMLParser.h"
 #include "llvm/Support/YAMLTraits.h"
 #include "llvm/Support/raw_ostream.h"
-#include <algorithm>
 
 using namespace clang::driver;
 using namespace clang;
Index: clang/lib/Driver/DriverOptions.cpp
===================================================================
--- clang/lib/Driver/DriverOptions.cpp
+++ clang/lib/Driver/DriverOptions.cpp
@@ -11,7 +11,6 @@
 #include "llvm/ADT/STLExtras.h"
 #include "llvm/Option/OptTable.h"
 #include "llvm/Option/Option.h"
-#include <cassert>
 
 using namespace clang::driver;
 using namespace clang::driver::options;
Index: clang/lib/Driver/Driver.cpp
===================================================================
--- clang/lib/Driver/Driver.cpp
+++ clang/lib/Driver/Driver.cpp
@@ -72,7 +72,6 @@
 #include "llvm/Support/TargetRegistry.h"
 #include "llvm/Support/raw_ostream.h"
 #include "llvm/Support/StringSaver.h"
-#include <map>
 #include <memory>
 #include <utility>
 #if LLVM_ON_UNIX


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D44508.138671.patch
Type: text/x-patch
Size: 2250 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20180316/f6d4d947/attachment.bin>


More information about the cfe-commits mailing list