initialise m_container

This commit is contained in:
Hieu Hoang 2014-08-04 15:20:22 +01:00
parent f844bd12d9
commit 5f90ccdb13
3 changed files with 4 additions and 4 deletions

View File

@ -50,7 +50,7 @@ TargetPhrase::TargetPhrase()
{
}
TargetPhrase::TargetPhrase(const Phrase &phrase)
TargetPhrase::TargetPhrase(const Phrase &phrase, const PhraseDictionary &pt)
: Phrase(phrase)
, m_fullScore(0.0)
, m_futureScore(0.0)
@ -58,7 +58,7 @@ TargetPhrase::TargetPhrase(const Phrase &phrase)
, m_alignNonTerm(&AlignmentInfoCollection::Instance().GetEmptyAlignmentInfo())
, m_lhsTarget(NULL)
, m_ruleSource(NULL)
, m_container(NULL)
, m_container(&pt)
{
}

View File

@ -66,7 +66,7 @@ private:
public:
TargetPhrase();
TargetPhrase(const TargetPhrase &copy);
TargetPhrase(const TargetPhrase &copy, const PhraseDictionary &pt);
explicit TargetPhrase(const Phrase &targetPhrase);
~TargetPhrase();

View File

@ -222,7 +222,7 @@ bool RuleTableLoaderCompact::LoadRuleSection(
// The remaining columns are currently ignored.
// Create and score target phrase.
TargetPhrase *targetPhrase = new TargetPhrase(targetPhrasePhrase);
TargetPhrase *targetPhrase = new TargetPhrase(targetPhrasePhrase, &ruleTable);
targetPhrase->SetAlignNonTerm(alignNonTerm);
targetPhrase->SetTargetLHS(targetLhs);