aboutsummaryrefslogtreecommitdiff
path: root/include/clang/Lex
diff options
context:
space:
mode:
Diffstat (limited to 'include/clang/Lex')
-rw-r--r--include/clang/Lex/HeaderSearch.h6
-rw-r--r--include/clang/Lex/ModuleMap.h12
2 files changed, 14 insertions, 4 deletions
diff --git a/include/clang/Lex/HeaderSearch.h b/include/clang/Lex/HeaderSearch.h
index c5969489f5..84bb37da3a 100644
--- a/include/clang/Lex/HeaderSearch.h
+++ b/include/clang/Lex/HeaderSearch.h
@@ -189,7 +189,7 @@ class HeaderSearch {
public:
HeaderSearch(FileManager &FM, DiagnosticsEngine &Diags,
- const LangOptions &LangOpts);
+ const LangOptions &LangOpts, const TargetInfo *Target);
~HeaderSearch();
FileManager &getFileMgr() const { return FileMgr; }
@@ -243,6 +243,10 @@ public:
ExternalSource = ES;
}
+ /// \brief Set the target information for the header search, if not
+ /// already known.
+ void setTarget(const TargetInfo &Target);
+
/// LookupFile - Given a "foo" or <foo> reference, look up the indicated file,
/// return null on failure.
///
diff --git a/include/clang/Lex/ModuleMap.h b/include/clang/Lex/ModuleMap.h
index 3e794f5c00..6176ed8c30 100644
--- a/include/clang/Lex/ModuleMap.h
+++ b/include/clang/Lex/ModuleMap.h
@@ -39,7 +39,8 @@ class ModuleMap {
SourceManager *SourceMgr;
llvm::IntrusiveRefCntPtr<DiagnosticsEngine> Diags;
const LangOptions &LangOpts;
-
+ const TargetInfo *Target;
+
/// \brief Language options used to parse the module map itself.
///
/// These are always simple C language options.
@@ -89,13 +90,18 @@ public:
/// diagnostics.
///
/// \param LangOpts Language options for this translation unit.
+ ///
+ /// \param Target The target for this translation unit.
ModuleMap(FileManager &FileMgr, const DiagnosticConsumer &DC,
- const LangOptions &LangOpts);
+ const LangOptions &LangOpts, const TargetInfo *Target);
/// \brief Destroy the module map.
///
~ModuleMap();
-
+
+ /// \brief Set the target information.
+ void setTarget(const TargetInfo &Target);
+
/// \brief Retrieve the module that owns the given header file, if any.
///
/// \param File The header file that is likely to be included.