diff options
| author | 2019-01-27 16:42:12 +0000 | |
|---|---|---|
| committer | 2019-01-27 16:42:12 +0000 | |
| commit | b773203fb58f3ef282fb69c832d8710cab5bc82d (patch) | |
| tree | e75913f147570fbd75169647b144df85b88a038c /gnu/llvm/tools/clang/lib/FrontendTool/ExecuteCompilerInvocation.cpp | |
| parent | tweak errno in previous (diff) | |
| download | wireguard-openbsd-b773203fb58f3ef282fb69c832d8710cab5bc82d.tar.xz wireguard-openbsd-b773203fb58f3ef282fb69c832d8710cab5bc82d.zip | |
Import LLVM 7.0.1 release including clang, lld and lldb.
Diffstat (limited to 'gnu/llvm/tools/clang/lib/FrontendTool/ExecuteCompilerInvocation.cpp')
| -rw-r--r-- | gnu/llvm/tools/clang/lib/FrontendTool/ExecuteCompilerInvocation.cpp | 13 |
1 files changed, 10 insertions, 3 deletions
diff --git a/gnu/llvm/tools/clang/lib/FrontendTool/ExecuteCompilerInvocation.cpp b/gnu/llvm/tools/clang/lib/FrontendTool/ExecuteCompilerInvocation.cpp index 4167e1fe20b..747fdd24164 100644 --- a/gnu/llvm/tools/clang/lib/FrontendTool/ExecuteCompilerInvocation.cpp +++ b/gnu/llvm/tools/clang/lib/FrontendTool/ExecuteCompilerInvocation.cpp @@ -32,6 +32,8 @@ using namespace clang; using namespace llvm::opt; +namespace clang { + static std::unique_ptr<FrontendAction> CreateFrontendBaseAction(CompilerInstance &CI) { using namespace clang::frontend; @@ -43,6 +45,8 @@ CreateFrontendBaseAction(CompilerInstance &CI) { case ASTDump: return llvm::make_unique<ASTDumpAction>(); case ASTPrint: return llvm::make_unique<ASTPrintAction>(); case ASTView: return llvm::make_unique<ASTViewAction>(); + case DumpCompilerOptions: + return llvm::make_unique<DumpCompilerOptionsAction>(); case DumpRawTokens: return llvm::make_unique<DumpRawTokensAction>(); case DumpTokens: return llvm::make_unique<DumpTokensAction>(); case EmitAssembly: return llvm::make_unique<EmitAssemblyAction>(); @@ -63,6 +67,7 @@ CreateFrontendBaseAction(CompilerInstance &CI) { case ParseSyntaxOnly: return llvm::make_unique<SyntaxOnlyAction>(); case ModuleFileInfo: return llvm::make_unique<DumpModuleInfoAction>(); case VerifyPCH: return llvm::make_unique<VerifyPCHAction>(); + case TemplightDump: return llvm::make_unique<TemplightDumpAction>(); case PluginAction: { for (FrontendPluginRegistry::iterator it = @@ -122,7 +127,7 @@ CreateFrontendBaseAction(CompilerInstance &CI) { #endif } -static std::unique_ptr<FrontendAction> +std::unique_ptr<FrontendAction> CreateFrontendAction(CompilerInstance &CI) { // Create the underlying action. std::unique_ptr<FrontendAction> Act = CreateFrontendBaseAction(CI); @@ -134,7 +139,7 @@ CreateFrontendAction(CompilerInstance &CI) { if (FEOpts.FixAndRecompile) { Act = llvm::make_unique<FixItRecompile>(std::move(Act)); } - + #if CLANG_ENABLE_ARCMT if (CI.getFrontendOpts().ProgramAction != frontend::MigrateSource && CI.getFrontendOpts().ProgramAction != frontend::GeneratePCH) { @@ -173,7 +178,7 @@ CreateFrontendAction(CompilerInstance &CI) { return Act; } -bool clang::ExecuteCompilerInvocation(CompilerInstance *Clang) { +bool ExecuteCompilerInvocation(CompilerInstance *Clang) { // Honor -help. if (Clang->getFrontendOpts().ShowHelp) { std::unique_ptr<OptTable> Opts = driver::createDriverOptTable(); @@ -254,3 +259,5 @@ bool clang::ExecuteCompilerInvocation(CompilerInstance *Clang) { BuryPointer(std::move(Act)); return Success; } + +} // namespace clang |
