From 3767d161c1107443c8cd86672054cee5f56b8287 Mon Sep 17 00:00:00 2001 From: Hieu Hoang Date: Thu, 18 Feb 2016 10:46:08 -0500 Subject: [PATCH] Revert "cleanup" This reverts commit 587c1a9f54c0d733c23084879530353e4bde0f43. --- contrib/other-builds/moses2/LM/KENLM.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/contrib/other-builds/moses2/LM/KENLM.cpp b/contrib/other-builds/moses2/LM/KENLM.cpp index 97cc2a0a2..2ba43e094 100644 --- a/contrib/other-builds/moses2/LM/KENLM.cpp +++ b/contrib/other-builds/moses2/LM/KENLM.cpp @@ -206,8 +206,9 @@ void KENLM::EvaluateWhenApplied(const Manager &mgr, const std::size_t adjust_end = std::min(end, begin + m_ngram->Order() - 1); std::size_t position = begin; + typename Model::State aux_state; const Model::State *state0 = stateCast.state; - const Model::State *state1; + const Model::State *state1 = &aux_state; const LMCacheValue &val = ScoreAndCache(mgr, *in_state, TranslateID(hypo.GetWord(position))); float score = val.first;