diff --git a/src/macro/Environment.cc b/src/macro/Environment.cc index 03206a2bf6dda8975e81811d9d2c9f60ab281e47..fcb8aa5c3de128d221ac24d5c6c9fcf99d6eef91 100644 --- a/src/macro/Environment.cc +++ b/src/macro/Environment.cc @@ -110,7 +110,7 @@ Environment::print(ostream &output, int line, bool save) const { output << (save ? "options_.macrovars_line_" + to_string(line) + "." : " " ); output << it.first << " = "; - getVariable(it.first)->eval()->print(output, true); + getVariable(it.first)->eval()->print(output, save); if (save) output << ";"; output << endl; diff --git a/src/macro/Expressions.cc b/src/macro/Expressions.cc index e7cff48807304c03c518b9913017a0d841e31c1c..4b1b6fa2d079f0a7898364dd9fed554ccd50983f 100644 --- a/src/macro/Expressions.cc +++ b/src/macro/Expressions.cc @@ -913,7 +913,8 @@ Comprehension::eval() { auto mt2 = dynamic_pointer_cast<Tuple>(btp); if (mt->size() != mt2->size()) - throw StackTrace("Comprehension", "The number of elements in the input set tuple are not the same as the number of elements in the output expression tuple", location); + throw StackTrace("Comprehension", "The number of elements in the input set tuple are not " + "the same as the number of elements in the output expression tuple", location); for (size_t j = 0; j < mt->size(); j++) { @@ -924,7 +925,8 @@ Comprehension::eval() } } else - throw StackTrace("Comprehension", "assigning to tuple in output expression but input expression does not contain tuples", location); + throw StackTrace("Comprehension", "assigning to tuple in output expression " + "but input expression does not contain tuples", location); DoublePtr dp; BoolPtr bp; @@ -1132,7 +1134,7 @@ String::print(ostream &output, bool matlab_output) const noexcept void Array::print(ostream &output, bool matlab_output) const noexcept { -output << (matlab_output ? "{" : "["); + output << (matlab_output ? "{" : "["); for (auto it = arr.begin(); it != arr.end(); it++) { if (it != arr.begin()) diff --git a/src/macro/Parser.yy b/src/macro/Parser.yy index cf1b4c4bc758fb9ebfda3b24def847f03cd192f0..85972412fd4e8e055cf7d7248e9dc89363c76368 100644 --- a/src/macro/Parser.yy +++ b/src/macro/Parser.yy @@ -82,7 +82,6 @@ using namespace macro; %left TIMES DIVIDE %precedence UMINUS UPLUS NOT %nonassoc POWER - //%precedence LBRACKET %token <string> NAME TEXT QUOTED_STRING NUMBER EOL