diff options
author | Stefan Radomski <sradomski@mintwerk.de> | 2015-07-08 20:03:03 (GMT) |
---|---|---|
committer | Stefan Radomski <sradomski@mintwerk.de> | 2015-07-08 20:03:03 (GMT) |
commit | 57ba362eae6e8209cf560555fd4cc4bb76dbe2a1 (patch) | |
tree | 00a2e2c5fd6993a5ee118df147cae3ef6e9cca9a /src/uscxml/plugins/datamodel/prolog/swi/SWIDataModel.cpp | |
parent | f02d7e5919f16d8396839fcff1e0588d6ccf3004 (diff) | |
download | uscxml-57ba362eae6e8209cf560555fd4cc4bb76dbe2a1.zip uscxml-57ba362eae6e8209cf560555fd4cc4bb76dbe2a1.tar.gz uscxml-57ba362eae6e8209cf560555fd4cc4bb76dbe2a1.tar.bz2 |
done.event bug and prolog tests
Fixed the done.event bug and added first prolog transformed IRP tests
Diffstat (limited to 'src/uscxml/plugins/datamodel/prolog/swi/SWIDataModel.cpp')
-rw-r--r-- | src/uscxml/plugins/datamodel/prolog/swi/SWIDataModel.cpp | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/uscxml/plugins/datamodel/prolog/swi/SWIDataModel.cpp b/src/uscxml/plugins/datamodel/prolog/swi/SWIDataModel.cpp index f6131f8..21b390a 100644 --- a/src/uscxml/plugins/datamodel/prolog/swi/SWIDataModel.cpp +++ b/src/uscxml/plugins/datamodel/prolog/swi/SWIDataModel.cpp @@ -689,7 +689,9 @@ bool SWIDataModel::evalAsBool(const Arabica::DOM::Element<std::string>& node, co } PlQuery query(compound.name(), termv); return query.next_solution() > 0; - } catch(...) { + } + RETHROW_PLEX_AS_EVENT + catch(...) { return false; } } @@ -823,7 +825,7 @@ void SWIDataModel::assign(const Element<std::string>& assignElem, PlCall(dataInitStr.str().c_str()); } else { // treat content as . seperated facts - std::stringstream factStream(content); + std::stringstream factStream(expr); std::string item; while(std::getline(factStream, item, '.')) { std::string fact = boost::trim_copy(item); |