Ensure that “pac_expectation” operators are never inserted into a static model

The implementation of PacExpectationNode::toStatic() did not make sense. It
should normally never be called, hence we error out at this point.

Also do a cosmetic change in the PacExpectationNode::clone() methode.
var-models
Sébastien Villemot 2021-07-21 14:37:34 +02:00
parent b16ab9b247
commit 0d6eb053d4
No known key found for this signature in database
GPG Key ID: 2CECE9350ECEBE4A
1 changed files with 3 additions and 2 deletions

View File

@ -8324,13 +8324,14 @@ PacExpectationNode::computeBlockTemporaryTerms(int blk, int eq, vector<vector<te
expr_t
PacExpectationNode::toStatic(DataTree &static_datatree) const
{
return static_datatree.AddPacExpectation(string(model_name));
cerr << "PacExpectationNode::toStatic not implemented." << endl;
exit(EXIT_FAILURE);
}
expr_t
PacExpectationNode::clone(DataTree &datatree) const
{
return datatree.AddPacExpectation(string(model_name));
return datatree.AddPacExpectation(model_name);
}
void