diff options
Diffstat (limited to 'tools/diagtool/ShowEnabledWarnings.cpp')
-rw-r--r-- | tools/diagtool/ShowEnabledWarnings.cpp | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/tools/diagtool/ShowEnabledWarnings.cpp b/tools/diagtool/ShowEnabledWarnings.cpp index 06f7432..abbd3af 100644 --- a/tools/diagtool/ShowEnabledWarnings.cpp +++ b/tools/diagtool/ShowEnabledWarnings.cpp @@ -64,9 +64,11 @@ createDiagnostics(unsigned int argc, char **argv) { new DiagnosticsEngine(DiagIDs, new DiagnosticOptions(), DiagsBuffer)); // Try to build a CompilerInvocation. + SmallVector<const char *, 4> Args; + Args.push_back("diagtool"); + Args.append(argv, argv + argc); std::unique_ptr<CompilerInvocation> Invocation( - createInvocationFromCommandLine(llvm::makeArrayRef(argv, argc), - InterimDiags)); + createInvocationFromCommandLine(Args, InterimDiags)); if (!Invocation) return nullptr; |