[PATCH] D66731: [Driver] Add an option for createInvocationFromCommandLine to recover on errors
Ilya Biryukov via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Mon Aug 26 03:09:19 PDT 2019
ilya-biryukov created this revision.
ilya-biryukov added a reviewer: gribozavr.
Herald added subscribers: kadircet, arphaman, jkorous.
Herald added a project: clang.
Previously, it would always return nullptr on any error.
This change adds a parameter, controlling whether the function should
attempt to return a non-null result even if unknown arguments (or other
errors were encountered).
The new behavior is only used in clangd.
Considered an alternative of changing the return value instead of adding
a new parameter, but that would require updating all callsites. Settled
with the parameter to minimize the code changes.
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D66731
Files:
clang-tools-extra/clangd/Compiler.cpp
clang-tools-extra/clangd/unittests/ClangdUnitTests.cpp
clang/include/clang/Frontend/Utils.h
clang/lib/Frontend/CreateInvocationFromCommandLine.cpp
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D66731.217100.patch
Type: text/x-patch
Size: 4818 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20190826/65e8c5d4/attachment.bin>
More information about the cfe-commits
mailing list