summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorUlf Hermann <ulf.hermann@qt.io>2016-11-24 16:17:20 +0100
committerUlf Hermann <ulf.hermann@qt.io>2016-12-19 09:23:27 +0000
commit51db93cf783662a155ced91dceef7508ffa955a6 (patch)
tree52fc72bb59cad1a04d9f19bb6892b0d0082c84c3
parent10bcb2ee73b557a9dfd72143f7bf0b42c607ecaf (diff)
Resolve the mixup of various ID types
We should not compare instances of different IDs with one another. Change-Id: I830d747ffde4c162c73475a600cef23e10c898e5 Reviewed-by: Erik Verbruggen <erik.verbruggen@qt.io>
-rw-r--r--src/scxml/qscxmlinvokableservice.cpp2
-rw-r--r--src/scxml/qscxmltabledata.cpp6
-rw-r--r--src/scxml/qscxmltabledata_p.h2
-rw-r--r--tools/qscxmlc/scxmlcppdumper.cpp4
4 files changed, 7 insertions, 7 deletions
diff --git a/src/scxml/qscxmlinvokableservice.cpp b/src/scxml/qscxmlinvokableservice.cpp
index 9af6be7..c608e3d 100644
--- a/src/scxml/qscxmlinvokableservice.cpp
+++ b/src/scxml/qscxmlinvokableservice.cpp
@@ -73,7 +73,7 @@ QScxmlStateMachine *QScxmlInvokableService::parentStateMachine() const
void QScxmlInvokableService::finalize(QScxmlExecutableContent::ContainerId finalize)
{
- if (finalize != QScxmlExecutableContent::NoInstruction) {
+ if (finalize != QScxmlExecutableContent::NoContainer) {
auto psm = parentStateMachine();
qCDebug(qscxmlLog) << psm << "running finalize on event";
auto smp = QScxmlStateMachinePrivate::get(psm);
diff --git a/src/scxml/qscxmltabledata.cpp b/src/scxml/qscxmltabledata.cpp
index 2457840..5d5115e 100644
--- a/src/scxml/qscxmltabledata.cpp
+++ b/src/scxml/qscxmltabledata.cpp
@@ -68,7 +68,7 @@ public:
{
m_activeSequences.reserve(4);
- tableData.theInitialSetup = QScxmlExecutableContent::NoInstruction;
+ tableData.theInitialSetup = QScxmlExecutableContent::NoContainer;
}
void buildTableData(DocumentModel::ScxmlDocument *doc)
@@ -264,7 +264,7 @@ protected: // visitor
params.append(p);
}
QScxmlExecutableContent::ContainerId finalize =
- QScxmlExecutableContent::NoInstruction;
+ QScxmlExecutableContent::NoContainer;
if (!invoke->finalize.isEmpty()) {
finalize = startNewSequence();
visit(&invoke->finalize);
@@ -528,7 +528,7 @@ protected:
ContainerId generate(const DocumentModel::InstructionSequences &inSequences)
{
if (inSequences.isEmpty())
- return NoInstruction;
+ return NoContainer;
auto id = m_instructions.newContainerId();
auto outSequences = m_instructions.add<InstructionSequences>();
diff --git a/src/scxml/qscxmltabledata_p.h b/src/scxml/qscxmltabledata_p.h
index 2c825db..767b88a 100644
--- a/src/scxml/qscxmltabledata_p.h
+++ b/src/scxml/qscxmltabledata_p.h
@@ -117,7 +117,7 @@ public:
QVector<QScxmlExecutableContent::AssignmentInfo> theAssignments;
QVector<QScxmlExecutableContent::ForeachInfo> theForeaches;
QVector<QScxmlExecutableContent::StringId> theDataNameIds;
- QScxmlExecutableContent::EvaluatorId theInitialSetup;
+ QScxmlExecutableContent::ContainerId theInitialSetup;
int theName;
};
} // QScxmlInternal namespace
diff --git a/tools/qscxmlc/scxmlcppdumper.cpp b/tools/qscxmlc/scxmlcppdumper.cpp
index b539e0d..81b9dcf 100644
--- a/tools/qscxmlc/scxmlcppdumper.cpp
+++ b/tools/qscxmlc/scxmlcppdumper.cpp
@@ -374,7 +374,7 @@ int createFactoryId(QStringList &factories, const QString &className,
const int idx = factories.size();
QString line = QStringLiteral("case %1: return new ").arg(QString::number(idx));
- if (invokeInfo.expr == QScxmlExecutableContent::NoInstruction) {
+ if (invokeInfo.expr == QScxmlExecutableContent::NoEvaluator) {
line += QStringLiteral("QScxmlStaticScxmlServiceFactory< %1::%2 >(")
.arg(namespacePrefix, className);
} else {
@@ -445,7 +445,7 @@ void CppDumper::dump(TranslationUnit *unit)
const QVector<QScxmlExecutableContent::ParameterInfo> &parameters,
const QSharedPointer<DocumentModel::ScxmlDocument> &content) -> int {
QString className;
- if (invokeInfo.expr == QScxmlExecutableContent::NoInstruction) {
+ if (invokeInfo.expr == QScxmlExecutableContent::NoEvaluator) {
className = mangleIdentifier(classnameForDocument.value(content.data()));
}
return createFactoryId(factories[i], className, namespacePrefix,