More consistent catch statements

Also take const& in all cases.
This commit is contained in:
Alex Beregszaszi
2018-07-25 01:18:09 +01:00
parent ae0959ae12
commit a5a61a0b77
3 changed files with 4 additions and 4 deletions
+1 -1
View File
@@ -115,7 +115,7 @@ pair<CheckResult, vector<string>> CVC4Interface::check(vector<Expression> const&
values.push_back(toString(m_solver.getValue(toCVC4Expr(e))));
}
}
catch (CVC4::Exception & e)
catch (CVC4::Exception const&)
{
result = CheckResult::ERROR;
values.clear();
+2 -2
View File
@@ -600,7 +600,7 @@ string StandardCompiler::compile(string const& _input)
if (!jsonParseStrict(_input, input, &errors))
return jsonCompactPrint(formatFatalError("JSONError", errors));
}
catch(...)
catch (...)
{
return "{\"errors\":\"[{\"type\":\"JSONError\",\"component\":\"general\",\"severity\":\"error\",\"message\":\"Error parsing input JSON.\"}]}";
}
@@ -613,7 +613,7 @@ string StandardCompiler::compile(string const& _input)
{
return jsonCompactPrint(output);
}
catch(...)
catch (...)
{
return "{\"errors\":\"[{\"type\":\"JSONError\",\"component\":\"general\",\"severity\":\"error\",\"message\":\"Error writing output JSON.\"}]}";
}