mirror of
https://github.com/MaskRay/ccls.git
synced 2024-11-28 18:41:57 +00:00
Adapt llvmorg-12-init-5498-g257b29715bb: add an argument to the ctor of clang::driver::Driver
This commit is contained in:
parent
20a9f7b5f4
commit
a3c5d4a1eb
@ -115,7 +115,11 @@ buildCompilerInvocation(const std::string &main, std::vector<const char *> args,
|
|||||||
IntrusiveRefCntPtr<DiagnosticsEngine> diags(
|
IntrusiveRefCntPtr<DiagnosticsEngine> diags(
|
||||||
CompilerInstance::createDiagnostics(new DiagnosticOptions,
|
CompilerInstance::createDiagnostics(new DiagnosticOptions,
|
||||||
new IgnoringDiagConsumer, true));
|
new IgnoringDiagConsumer, true));
|
||||||
|
#if LLVM_VERSION_MAJOR < 12 // llvmorg-12-init-5498-g257b29715bb
|
||||||
driver::Driver d(args[0], llvm::sys::getDefaultTargetTriple(), *diags, vfs);
|
driver::Driver d(args[0], llvm::sys::getDefaultTargetTriple(), *diags, vfs);
|
||||||
|
#else
|
||||||
|
driver::Driver d(args[0], llvm::sys::getDefaultTargetTriple(), *diags, "ccls", vfs);
|
||||||
|
#endif
|
||||||
d.setCheckInputsExist(false);
|
d.setCheckInputsExist(false);
|
||||||
std::unique_ptr<driver::Compilation> comp(d.BuildCompilation(args));
|
std::unique_ptr<driver::Compilation> comp(d.BuildCompilation(args));
|
||||||
if (!comp)
|
if (!comp)
|
||||||
|
Loading…
Reference in New Issue
Block a user