diff --git a/copasi/function/CEvaluationNodeObject.cpp b/copasi/function/CEvaluationNodeObject.cpp index 4073b06b93..724dc509a1 100644 --- a/copasi/function/CEvaluationNodeObject.cpp +++ b/copasi/function/CEvaluationNodeObject.cpp @@ -140,6 +140,7 @@ CIssue CEvaluationNodeObject::compile() return CIssue(CIssue::eSeverity::Error, CIssue::eKind::StructureInvalid); } + getData(); mRegisteredObjectCN = CRegisteredCommonName(mData.substr(1, mData.length() - 2), mpTree); mpObject = mpTree->getNodeObject(mRegisteredObjectCN); @@ -163,7 +164,7 @@ CIssue CEvaluationNodeObject::compile() { mpObject = pObject; mRegisteredObjectCN = mpObject->getCN(); - mData = getData(); + getData(); } if (pDataObject->hasFlag(CDataObject::ValueDbl)) @@ -186,8 +187,6 @@ CIssue CEvaluationNodeObject::compile() return CIssue(CIssue::eSeverity::Error, CIssue::eKind::ValueNotFound); } - - mData = "<" + mRegisteredObjectCN + ">"; } break; @@ -229,6 +228,7 @@ CIssue CEvaluationNodeObject::compile() return CIssue(CIssue::eSeverity::Error, CIssue::eKind::StructureInvalid); } + getData(); mRegisteredObjectCN = CRegisteredCommonName(mData.substr(1, mData.length() - 2), mpTree); mpObject = mpTree->getNodeObject(mRegisteredObjectCN); @@ -362,6 +362,7 @@ std::string CEvaluationNodeObject::getInfix(const std::vector< std::string > & / switch (mSubType) { case SubType::CN: + case SubType::AVOGADRO: return "<" + mRegisteredObjectCN + ">"; break; diff --git a/copasi/model/CModelValue.cpp b/copasi/model/CModelValue.cpp index ea4d2bb1c0..7cef68f57b 100644 --- a/copasi/model/CModelValue.cpp +++ b/copasi/model/CModelValue.cpp @@ -430,14 +430,16 @@ std::string CModelEntity::getExpression() const CExpression* CModelEntity::getExpressionPtr() { - if (mpExpression != NULL) mpExpression->updateInfix(); + if (mpExpression != NULL) + mpExpression->updateInfix(); return mpExpression; } const CExpression* CModelEntity::getExpressionPtr() const { - if (mpExpression != NULL) mpExpression->updateInfix(); + if (mpExpression != NULL) + mpExpression->updateInfix(); return mpExpression; }