clang-cl: Support /showIncludes
This option prints information about #included files to stderr. Clang could
already do it, this patch just teaches the existing code about the /showIncludes
style and adds the flag.
Differential Revision: http://llvm-reviews.chandlerc.com/D1333
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@188037 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/lib/Driver/Tools.cpp b/lib/Driver/Tools.cpp
index 7724a1e..1d41b94 100644
--- a/lib/Driver/Tools.cpp
+++ b/lib/Driver/Tools.cpp
@@ -3727,6 +3727,9 @@
// FIXME: Make this default for the win32 triple.
CmdArgs.push_back("-cxx-abi");
CmdArgs.push_back("microsoft");
+
+ if (Arg *A = Args.getLastArg(options::OPT_show_includes))
+ A->render(Args, CmdArgs);
}
void ClangAs::ConstructJob(Compilation &C, const JobAction &JA,