diff options
| author | Hans Wennborg <hans@hanshq.net> | 2013-08-09 00:32:23 +0000 |
|---|---|---|
| committer | Hans Wennborg <hans@hanshq.net> | 2013-08-09 00:32:23 +0000 |
| commit | 708002ede3938256a6223d153a0c040f7a40f5cc (patch) | |
| tree | a92d6d3a1a2debf58ffaa014af43c1feb52ebf87 /lib/Frontend/CompilerInstance.cpp | |
| parent | c8e8e8faff9c21952cca04be664c8e25bd599300 (diff) | |
| download | clang-708002ede3938256a6223d153a0c040f7a40f5cc.tar.gz clang-708002ede3938256a6223d153a0c040f7a40f5cc.tar.bz2 clang-708002ede3938256a6223d153a0c040f7a40f5cc.tar.xz | |
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
Diffstat (limited to 'lib/Frontend/CompilerInstance.cpp')
| -rw-r--r-- | lib/Frontend/CompilerInstance.cpp | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/lib/Frontend/CompilerInstance.cpp b/lib/Frontend/CompilerInstance.cpp index f06eaf8736..d2e9368506 100644 --- a/lib/Frontend/CompilerInstance.cpp +++ b/lib/Frontend/CompilerInstance.cpp @@ -259,7 +259,7 @@ void CompilerInstance::createPreprocessor() { AttachDependencyGraphGen(*PP, DepOpts.DOTOutputFile, getHeaderSearchOpts().Sysroot); - + // Handle generating header include information, if requested. if (DepOpts.ShowHeaderIncludes) AttachHeaderIncludeGen(*PP); @@ -270,6 +270,11 @@ void CompilerInstance::createPreprocessor() { AttachHeaderIncludeGen(*PP, /*ShowAllHeaders=*/true, OutputPath, /*ShowDepth=*/false); } + + if (DepOpts.PrintShowIncludes) { + AttachHeaderIncludeGen(*PP, /*ShowAllHeaders=*/false, /*OutputPath=*/"", + /*ShowDepth=*/true, /*MSStyle=*/true); + } } // ASTContext |
