summaryrefslogtreecommitdiffstats
path: root/Source/cmGeneratorExpressionNode.cxx
diff options
context:
space:
mode:
authorBruno Manganelli <bruno.manga95@gmail.com>2018-11-22 03:36:50 (GMT)
committerBrad King <brad.king@kitware.com>2019-01-16 13:16:31 (GMT)
commitcc2a5261f82c21e15899bba0d9b508fcacda7879 (patch)
tree38d9e0113178cd43c7f42898392452b6a8e8e84a /Source/cmGeneratorExpressionNode.cxx
parentda566d4de885130e182edc80f13691f5ca24bb61 (diff)
downloadCMake-cc2a5261f82c21e15899bba0d9b508fcacda7879.zip
CMake-cc2a5261f82c21e15899bba0d9b508fcacda7879.tar.gz
CMake-cc2a5261f82c21e15899bba0d9b508fcacda7879.tar.bz2
Factor out enum MessageType into dedicated header
Reduce the number of files relying on `cmake.h`.
Diffstat (limited to 'Source/cmGeneratorExpressionNode.cxx')
-rw-r--r--Source/cmGeneratorExpressionNode.cxx11
1 files changed, 6 insertions, 5 deletions
diff --git a/Source/cmGeneratorExpressionNode.cxx b/Source/cmGeneratorExpressionNode.cxx
index 627e66d..fe1b055 100644
--- a/Source/cmGeneratorExpressionNode.cxx
+++ b/Source/cmGeneratorExpressionNode.cxx
@@ -12,6 +12,7 @@
#include "cmLinkItem.h"
#include "cmLocalGenerator.h"
#include "cmMakefile.h"
+#include "cmMessageType.h"
#include "cmOutputConverter.h"
#include "cmPolicies.h"
#include "cmStateTypes.h"
@@ -304,7 +305,7 @@ static const struct InListNode : public cmGeneratorExpressionNode
<< "\nSearch Item:\n \"" << parameters.front()
<< "\"\nList:\n \"" << parameters[1] << "\"\n";
context->LG->GetCMakeInstance()->IssueMessage(
- cmake::AUTHOR_WARNING, e.str(), context->Backtrace);
+ MessageType ::AUTHOR_WARNING, e.str(), context->Backtrace);
return "0";
}
if (values.empty()) {
@@ -632,7 +633,7 @@ struct CompilerIdNode : public cmGeneratorExpressionNode
std::ostringstream e;
e << cmPolicies::GetPolicyWarning(cmPolicies::CMP0044);
context->LG->GetCMakeInstance()->IssueMessage(
- cmake::AUTHOR_WARNING, e.str(), context->Backtrace);
+ MessageType::AUTHOR_WARNING, e.str(), context->Backtrace);
CM_FALLTHROUGH;
}
case cmPolicies::OLD:
@@ -1654,7 +1655,7 @@ static const struct TargetPolicyNode : public cmGeneratorExpressionNode
switch (statusForTarget(context->HeadTarget, policy)) {
case cmPolicies::WARN:
lg->IssueMessage(
- cmake::AUTHOR_WARNING,
+ MessageType::AUTHOR_WARNING,
cmPolicies::GetPolicyWarning(policyForString(policy)));
CM_FALLTHROUGH;
case cmPolicies::REQUIRED_IF_USED:
@@ -2096,6 +2097,6 @@ void reportError(cmGeneratorExpressionContext* context,
<< " " << expr << "\n"
<< result;
/* clang-format on */
- context->LG->GetCMakeInstance()->IssueMessage(cmake::FATAL_ERROR, e.str(),
- context->Backtrace);
+ context->LG->GetCMakeInstance()->IssueMessage(MessageType::FATAL_ERROR,
+ e.str(), context->Backtrace);
}