diff options
author | Hieu Hoang <fishandfrolick@gmail.com> | 2013-06-08 03:22:27 +0400 |
---|---|---|
committer | Hieu Hoang <fishandfrolick@gmail.com> | 2013-06-08 03:22:27 +0400 |
commit | 6f21727ecd3f78218bc426f32dc93a99893c202a (patch) | |
tree | d4956d62e1ba0485688336c9e6f7c53b6c2bb9d9 /moses/TargetPhraseCollection.cpp | |
parent | e8b1eb047cf067441a6a1a12316cffe027f35abb (diff) |
table limit = 0 means no limit, for on-disk
Diffstat (limited to 'moses/TargetPhraseCollection.cpp')
-rw-r--r-- | moses/TargetPhraseCollection.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/moses/TargetPhraseCollection.cpp b/moses/TargetPhraseCollection.cpp index 88ce28eb6..73f6d0543 100644 --- a/moses/TargetPhraseCollection.cpp +++ b/moses/TargetPhraseCollection.cpp @@ -65,7 +65,7 @@ void TargetPhraseCollection::Sort(bool adhereTableLimit, size_t tableLimit) std::partial_sort(m_collection.begin(), iterMiddle, m_collection.end(), CompareTargetPhrase()); - if (adhereTableLimit && m_collection.size() > tableLimit) { + if (adhereTableLimit && tableLimit && m_collection.size() > tableLimit) { for (size_t i = tableLimit; i < m_collection.size(); ++i) { TargetPhrase *targetPhrase = m_collection[i]; delete targetPhrase; |