diff options
| author | Simon Atanasyan <simon@atanasyan.com> | 2019-04-02 18:03:15 +0000 |
|---|---|---|
| committer | Simon Atanasyan <simon@atanasyan.com> | 2019-04-02 18:03:15 +0000 |
| commit | 6db2abd133f1a3451899c009ce459532dae33c16 (patch) | |
| tree | 9b0d3dbf77488ce4216d4fc43c6a17b950333a31 /lib/Driver/Driver.cpp | |
| parent | 5e8df5da17d424a3841722a9a7f6c3c4ab4b347c (diff) | |
| download | clang-6db2abd133f1a3451899c009ce459532dae33c16.tar.gz | |
[driver] clang-format. Fix indentation, split long lines. NFC
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@357505 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Driver/Driver.cpp')
| -rw-r--r-- | lib/Driver/Driver.cpp | 25 |
1 files changed, 15 insertions, 10 deletions
diff --git a/lib/Driver/Driver.cpp b/lib/Driver/Driver.cpp index 954c42ef9b..8b77a59cca 100644 --- a/lib/Driver/Driver.cpp +++ b/lib/Driver/Driver.cpp @@ -246,8 +246,9 @@ InputArgList Driver::ParseArgStrings(ArrayRef<const char *> ArgStrings, : diag::err_drv_unknown_argument; Diags.Report(DiagID) << ArgString; } else { - DiagID = IsCLMode() ? diag::warn_drv_unknown_argument_clang_cl_with_suggestion - : diag::err_drv_unknown_argument_with_suggestion; + DiagID = IsCLMode() + ? diag::warn_drv_unknown_argument_clang_cl_with_suggestion + : diag::err_drv_unknown_argument_with_suggestion; Diags.Report(DiagID) << ArgString << Nearest; } ContainsError |= Diags.getDiagnosticLevel(DiagID, SourceLocation()) > @@ -1417,11 +1418,13 @@ void Driver::generateCompilationDiagnostics( } void Driver::setUpResponseFiles(Compilation &C, Command &Cmd) { - // Since commandLineFitsWithinSystemLimits() may underestimate system's capacity - // if the tool does not support response files, there is a chance/ that things - // will just work without a response file, so we silently just skip it. + // Since commandLineFitsWithinSystemLimits() may underestimate system's + // capacity if the tool does not support response files, there is a chance/ + // that things will just work without a response file, so we silently just + // skip it. if (Cmd.getCreator().getResponseFilesSupport() == Tool::RF_None || - llvm::sys::commandLineFitsWithinSystemLimits(Cmd.getExecutable(), Cmd.getArguments())) + llvm::sys::commandLineFitsWithinSystemLimits(Cmd.getExecutable(), + Cmd.getArguments())) return; std::string TmpName = GetTemporaryPath("response", "txt"); @@ -2030,7 +2033,8 @@ void Driver::BuildInputs(const ToolChain &TC, DerivedArgList &Args, Arg *Previous = nullptr; bool ShowNote = false; - for (Arg *A : Args.filtered(options::OPT__SLASH_TC, options::OPT__SLASH_TP)) { + for (Arg *A : + Args.filtered(options::OPT__SLASH_TC, options::OPT__SLASH_TP)) { if (Previous) { Diag(clang::diag::warn_drv_overriding_flag_option) << Previous->getSpelling() << A->getSpelling(); @@ -4260,8 +4264,8 @@ const char *Driver::GetNamedOutputPath(Compilation &C, const JobAction &JA, SmallString<128> CrashDirectory(A->getValue()); llvm::sys::path::append(CrashDirectory, Split.first); const char *Middle = Suffix ? "-%%%%%%." : "-%%%%%%"; - std::error_code EC = - llvm::sys::fs::createUniqueFile(CrashDirectory + Middle + Suffix, TmpName); + std::error_code EC = llvm::sys::fs::createUniqueFile( + CrashDirectory + Middle + Suffix, TmpName); if (EC) { Diag(clang::diag::err_unable_to_make_temp) << EC.message(); return ""; @@ -4764,7 +4768,8 @@ bool Driver::GetReleaseVersion(StringRef Str, return false; } -std::pair<unsigned, unsigned> Driver::getIncludeExcludeOptionFlagMasks(bool IsClCompatMode) const { +std::pair<unsigned, unsigned> +Driver::getIncludeExcludeOptionFlagMasks(bool IsClCompatMode) const { unsigned IncludedFlagsBitmask = 0; unsigned ExcludedFlagsBitmask = options::NoDriverOption; |
