r346927 - Rewrite-imports on crash: Simplify handling
David Blaikie via cfe-commits
cfe-commits at lists.llvm.org
Wed Nov 14 19:04:20 PST 2018
Author: dblaikie
Date: Wed Nov 14 19:04:19 2018
New Revision: 346927
URL: http://llvm.org/viewvc/llvm-project?rev=346927&view=rev
Log:
Rewrite-imports on crash: Simplify handling
-frewrite-imports already implies -frewrite-includes (it piggy-backs
on/extends the implementation) so there's no need to conditionally pass
-frewrite-includes when already using -frewrite-imports (& especially I
don't think these would want to be different between crash reporting and
not crash reporting)
Modified:
cfe/trunk/lib/Driver/ToolChains/Clang.cpp
Modified: cfe/trunk/lib/Driver/ToolChains/Clang.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Driver/ToolChains/Clang.cpp?rev=346927&r1=346926&r2=346927&view=diff
==============================================================================
--- cfe/trunk/lib/Driver/ToolChains/Clang.cpp (original)
+++ cfe/trunk/lib/Driver/ToolChains/Clang.cpp Wed Nov 14 19:04:19 2018
@@ -4916,7 +4916,7 @@ void Clang::ConstructJob(Compilation &C,
// nice to enable this when doing a crashdump for modules as well.
if (Args.hasFlag(options::OPT_frewrite_includes,
options::OPT_fno_rewrite_includes, false) ||
- (C.isForDiagnostics() && (RewriteImports || !HaveModules)))
+ (C.isForDiagnostics() && !HaveModules))
CmdArgs.push_back("-frewrite-includes");
// Only allow -traditional or -traditional-cpp outside in preprocessing modes.
More information about the cfe-commits
mailing list