diff options
author | Dmitri Gribenko <gribozavr@gmail.com> | 2019-08-27 22:13:31 +0000 |
---|---|---|
committer | Dmitri Gribenko <gribozavr@gmail.com> | 2019-08-27 22:13:31 +0000 |
commit | 1fac68b0dc19b03fd2c5e9856f0f2c5a11691348 (patch) | |
tree | 8d34e81ec9a2821e079ca8f647d6d1c82c5309f6 /clang/lib/Frontend/CreateInvocationFromCommandLine.cpp | |
parent | d3136661bac0509328231005957fb27adc8ce717 (diff) | |
download | bcm5719-llvm-1fac68b0dc19b03fd2c5e9856f0f2c5a11691348.tar.gz bcm5719-llvm-1fac68b0dc19b03fd2c5e9856f0f2c5a11691348.zip |
ArrayRef'ized CompilerInvocation::CreateFromArgs
Subscribers: cfe-commits
Tags: #clang
Differential Revision: https://reviews.llvm.org/D66797
llvm-svn: 370122
Diffstat (limited to 'clang/lib/Frontend/CreateInvocationFromCommandLine.cpp')
-rw-r--r-- | clang/lib/Frontend/CreateInvocationFromCommandLine.cpp | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/clang/lib/Frontend/CreateInvocationFromCommandLine.cpp b/clang/lib/Frontend/CreateInvocationFromCommandLine.cpp index ea7de7a4111..ab62b633cda 100644 --- a/clang/lib/Frontend/CreateInvocationFromCommandLine.cpp +++ b/clang/lib/Frontend/CreateInvocationFromCommandLine.cpp @@ -90,9 +90,7 @@ std::unique_ptr<CompilerInvocation> clang::createInvocationFromCommandLine( const ArgStringList &CCArgs = Cmd.getArguments(); auto CI = std::make_unique<CompilerInvocation>(); - if (!CompilerInvocation::CreateFromArgs( - *CI, const_cast<const char **>(CCArgs.data()), - const_cast<const char **>(CCArgs.data()) + CCArgs.size(), *Diags) && + if (!CompilerInvocation::CreateFromArgs(*CI, CCArgs, *Diags) && !ShouldRecoverOnErorrs) return nullptr; return CI; |