Skip to content
Snippets Groups Projects
Commit 6baea06e authored by Paweł Kędzia's avatar Paweł Kędzia
Browse files

(swig) Handle exception thrown by Wccl::Parser::parseAnyOperator()

parent 0868a5b0
Branches
No related merge requests found
...@@ -77,6 +77,14 @@ namespace Wccl { ...@@ -77,6 +77,14 @@ namespace Wccl {
/* --------------------------------------------------------------------- */ /* --------------------------------------------------------------------- */
%exception {
try {
$action
} catch (PwrNlp::PwrNlpError &e) {
PyErr_SetString(PyExc_IndexError, e.info().c_str());
return NULL;
}
}
shared_ptr<FunctionalOperator> shared_ptr<FunctionalOperator>
parseAnyOperator(const std::string& operator_string) const; parseAnyOperator(const std::string& operator_string) const;
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment