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:
authorUlrich Germann <Ulrich.Germann@gmail.com>2015-12-10 02:05:00 +0300
committerUlrich Germann <Ulrich.Germann@gmail.com>2015-12-10 02:05:00 +0300
commit240b88c6834c9c94e8a6448a34dc4ad33bdf3fbd (patch)
treee9f43dba3717e8a430557c16a1d6543a13628ddf /moses/TranslationOptionCollectionConfusionNet.cpp
parentad5e27ae56298564dfd73637c160a682b5f5f028 (diff)
Passing around AllOptions or references thereto everywhere,
strong them locally where appropriate, so that compontents can become independent of StaticData once instantiated.
Diffstat (limited to 'moses/TranslationOptionCollectionConfusionNet.cpp')
-rw-r--r--moses/TranslationOptionCollectionConfusionNet.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/moses/TranslationOptionCollectionConfusionNet.cpp b/moses/TranslationOptionCollectionConfusionNet.cpp
index 1dc2af2c7..e108b72e2 100644
--- a/moses/TranslationOptionCollectionConfusionNet.cpp
+++ b/moses/TranslationOptionCollectionConfusionNet.cpp
@@ -41,7 +41,7 @@ TranslationOptionCollectionConfusionNet(ttasksptr const& ttask,
size_t inputSize = input.GetSize();
m_inputPathMatrix.resize(inputSize);
- size_t maxSizePhrase = ttask->options().search.max_phrase_length;
+ size_t maxSizePhrase = ttask->options()->search.max_phrase_length;
maxSizePhrase = std::min(inputSize, maxSizePhrase);
// 1-word phrases
@@ -225,7 +225,7 @@ CreateTranslationOptionsForRangeLEGACY(const DecodeGraph &decodeGraph,
bool retval = true;
size_t const max_phrase_length
= StaticData::Instance().options().search.max_phrase_length;
- XmlInputType intype = m_ttask.lock()->options().input.xml_policy;
+ XmlInputType intype = m_ttask.lock()->options()->input.xml_policy;
if ((intype != XmlExclusive) || !HasXmlOptionsOverlappingRange(startPos,endPos)) {
InputPathList &inputPathList = GetInputPathList(startPos, endPos);