diff options
author | Douglas Gregor <dgregor@apple.com> | 2013-03-20 21:10:35 +0000 |
---|---|---|
committer | Douglas Gregor <dgregor@apple.com> | 2013-03-20 21:10:35 +0000 |
commit | 906d66acc5cf2679453e10a4f0a67feedd765b21 (patch) | |
tree | 8c31690c89bdf0b16fedd5a2db26c49048824559 /include/clang/Basic/Module.h | |
parent | f8e2c06cea1548c437761cb65cfbf97d50a057a7 (diff) |
<rdar://problem/12368093> Extend module maps with a 'conflict' declaration, and warn when a newly-imported module conflicts with an already-imported module.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@177577 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include/clang/Basic/Module.h')
-rw-r--r-- | include/clang/Basic/Module.h | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/include/clang/Basic/Module.h b/include/clang/Basic/Module.h index 2add58019f..d2a43f0219 100644 --- a/include/clang/Basic/Module.h +++ b/include/clang/Basic/Module.h @@ -201,6 +201,31 @@ public: /// (intentionally) change how this module is built. std::vector<std::string> ConfigMacros; + /// \brief An unresolved conflict with another module. + struct UnresolvedConflict { + /// \brief The (unresolved) module id. + ModuleId Id; + + /// \brief The message provided to the user when there is a conflict. + std::string Message; + }; + + /// \brief The list of conflicts for which the module-id has not yet been + /// resolved. + std::vector<UnresolvedConflict> UnresolvedConflicts; + + /// \brief A conflict between two modules. + struct Conflict { + /// \brief The module that this module conflicts with. + Module *Other; + + /// \brief The message provided to the user when there is a conflict. + std::string Message; + }; + + /// \brief The list of conflicts. + std::vector<Conflict> Conflicts; + /// \brief Construct a top-level module. explicit Module(StringRef Name, SourceLocation DefinitionLoc, bool IsFramework) |