Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/moses-smt/mosesdecoder.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorhieuhoang1972 <hieuhoang1972@1f5c12ca-751b-0410-a591-d2e778427230>2010-04-20 20:04:20 +0400
committerhieuhoang1972 <hieuhoang1972@1f5c12ca-751b-0410-a591-d2e778427230>2010-04-20 20:04:20 +0400
commit36a15fd161a8055cf408ac68c5a8ab4ae2dece3c (patch)
tree1295e1cb5affb558088e1c517426271f2617f583
parenta1dc3aea25b2201d719589742a8d1fdaad021fdd (diff)
lex reordering bug, taken from trunkLAST-PHRASE-BASED-ONLY-2010-04-08
git-svn-id: https://mosesdecoder.svn.sourceforge.net/svnroot/mosesdecoder/tags/LAST-PHRASE-BASED-ONLY-2010-04-08@3149 1f5c12ca-751b-0410-a591-d2e778427230
-rw-r--r--moses/src/LexicalReorderingState.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/moses/src/LexicalReorderingState.cpp b/moses/src/LexicalReorderingState.cpp
index 2b181f65c..4fa9ea610 100644
--- a/moses/src/LexicalReorderingState.cpp
+++ b/moses/src/LexicalReorderingState.cpp
@@ -146,6 +146,9 @@ int LexicalReorderingState::ComparePrevScores(const Scores *other) const {
if(other == NULL)
return -1;
+ if(m_prevScore == NULL)
+ return +1;
+
const Scores &my = *m_prevScore;
const Scores &their = *other;
for(size_t i = m_offset; i < m_offset + m_configuration.GetNumberOfTypes(); i++)