forked from OSchip/llvm-project
[clangd] Make dexp command line options sticky
Preparing for the cl::opt reset fix proposed on D115433 this patch fixes the dexp tool to preserve its three command line options (IndexLocation, ExecCommand, ProjectRoot) from reset that is done before parsing query options. Tags: #clang
This commit is contained in:
parent
81f8df0c83
commit
c8a35727fe
|
@ -416,9 +416,9 @@ int main(int argc, const char *argv[]) {
|
|||
|
||||
// Preserve global options when flag parser is reset, so commands can use
|
||||
// them.
|
||||
IndexLocation.setValue(IndexLocation, /*initial=*/ true);
|
||||
ExecCommand.setValue(ExecCommand, /*initial=*/ true);
|
||||
ProjectRoot.setValue(ProjectRoot, /*initial=*/ true);
|
||||
IndexLocation.setValue(IndexLocation, /*initial=*/true);
|
||||
ExecCommand.setValue(ExecCommand, /*initial=*/true);
|
||||
ProjectRoot.setValue(ProjectRoot, /*initial=*/true);
|
||||
|
||||
llvm::cl::ResetCommandLineParser(); // We reuse it for REPL commands.
|
||||
llvm::sys::PrintStackTraceOnErrorSignal(argv[0]);
|
||||
|
|
Loading…
Reference in New Issue