diff options
author | graehl <graehl@ec762483-ff6d-05da-a07a-a48fb63a330f> | 2010-07-08 16:44:20 +0000 |
---|---|---|
committer | graehl <graehl@ec762483-ff6d-05da-a07a-a48fb63a330f> | 2010-07-08 16:44:20 +0000 |
commit | 337b647baac15609a0a493902d58c473d25d2ed8 (patch) | |
tree | 3827f59a180164878ee217f27f445c259c9e5bab /decoder/trule.cc | |
parent | 7386574a2c70c7ed6e937eb94e3add8023cd7327 (diff) |
--show_features
git-svn-id: https://ws10smt.googlecode.com/svn/trunk@184 ec762483-ff6d-05da-a07a-a48fb63a330f
Diffstat (limited to 'decoder/trule.cc')
-rw-r--r-- | decoder/trule.cc | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/decoder/trule.cc b/decoder/trule.cc index 505839c7..170e3a95 100644 --- a/decoder/trule.cc +++ b/decoder/trule.cc @@ -7,6 +7,11 @@ using namespace std; +bool TRule::IsGoal() const { + static const int kGOAL(TD::Convert("Goal") * -1); // this will happen once, and after static init of trule.cc static dict. + return GetLHS() == kGOAL; +} + static WordID ConvertTrgString(const string& w) { int len = w.size(); WordID id = 0; |