aboutsummaryrefslogtreecommitdiff
path: root/include/clang/Frontend/CompilerInvocation.h
diff options
context:
space:
mode:
authorDaniel Dunbar <daniel@zuster.org>2009-11-09 22:46:17 +0000
committerDaniel Dunbar <daniel@zuster.org>2009-11-09 22:46:17 +0000
commit26a0cac165aea204f661b8da7b167623b12ff143 (patch)
treed99d8e05418d674f67fe21eb846c7033179d0462 /include/clang/Frontend/CompilerInvocation.h
parent638c901ae3df86d3048b26768594673025578d65 (diff)
Move LangOptions, HeaderSearchOptions, and the target feature map into
CompilerInvocation. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@86612 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include/clang/Frontend/CompilerInvocation.h')
-rw-r--r--include/clang/Frontend/CompilerInvocation.h34
1 files changed, 30 insertions, 4 deletions
diff --git a/include/clang/Frontend/CompilerInvocation.h b/include/clang/Frontend/CompilerInvocation.h
index 7cd68e81a2..3416654481 100644
--- a/include/clang/Frontend/CompilerInvocation.h
+++ b/include/clang/Frontend/CompilerInvocation.h
@@ -10,7 +10,10 @@
#ifndef LLVM_CLANG_FRONTEND_COMPILERINVOCATION_H_
#define LLVM_CLANG_FRONTEND_COMPILERINVOCATION_H_
+#include "clang/Basic/LangOptions.h"
#include "clang/Frontend/DiagnosticOptions.h"
+#include "clang/Frontend/HeaderSearchOptions.h"
+#include "llvm/ADT/StringMap.h"
#include <string>
namespace clang {
@@ -26,16 +29,39 @@ class CompilerInvocation {
/// invocations which have no output.
std::string OutputFile;
- DiagnosticOptions Diags;
-
+ /// Options controlling the diagnostic engine.
+ DiagnosticOptions DiagOpts;
+
+ /// Set of target-specific code generation features to enable/disable.
+ llvm::StringMap<bool> TargetFeatures;
+
+ /// Options controlling the language variant.
+ LangOptions LangOpts;
+
+ /// Options controlling the #include directive.
+ HeaderSearchOptions HeaderSearchOpts;
+
public:
CompilerInvocation() {}
std::string &getOutputFile() { return OutputFile; }
const std::string &getOutputFile() const { return OutputFile; }
- DiagnosticOptions &getDiagnosticOpts() { return Diags; }
- const DiagnosticOptions &getDiagnosticOpts() const { return Diags; }
+ DiagnosticOptions &getDiagnosticOpts() { return DiagOpts; }
+ const DiagnosticOptions &getDiagnosticOpts() const { return DiagOpts; }
+
+ llvm::StringMap<bool> &getTargetFeatures() { return TargetFeatures; }
+ const llvm::StringMap<bool> &getTargetFeatures() const {
+ return TargetFeatures;
+ }
+
+ LangOptions &getLangOpts() { return LangOpts; }
+ const LangOptions &getLangOpts() const { return LangOpts; }
+
+ HeaderSearchOptions &getHeaderSearchOpts() { return HeaderSearchOpts; }
+ const HeaderSearchOptions &getHeaderSearchOpts() const {
+ return HeaderSearchOpts;
+ }
};
} // end namespace clang