From 7a7947889fb274b80557161b55db053c72ff3114 Mon Sep 17 00:00:00 2001 From: David Blaikie Date: Thu, 15 Nov 2018 03:04:19 +0000 Subject: [PATCH] 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) git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@346927 91177308-0d34-0410-b5e6-96231b3b80d8 --- lib/Driver/ToolChains/Clang.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/Driver/ToolChains/Clang.cpp b/lib/Driver/ToolChains/Clang.cpp index 17b93c2098..01525f46ba 100644 --- a/lib/Driver/ToolChains/Clang.cpp +++ b/lib/Driver/ToolChains/Clang.cpp @@ -4916,7 +4916,7 @@ void Clang::ConstructJob(Compilation &C, const JobAction &JA, // 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. -- 2.40.0