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 <ugermann@inf.ed.ac.uk>2014-05-31 17:33:31 +0400
committerUlrich Germann <ugermann@inf.ed.ac.uk>2014-05-31 17:33:31 +0400
commit249c40ec74f182cf92600341ea07de6666a6281a (patch)
treec07793b80139dde5bf1457c4b909fc51c1039eee /moses/Sentence.cpp
parentc4528753433dc6a8be5c50676504e1f68724f275 (diff)
Eliminated factor delimiter from the parameters of
Phrase.CreateFromString() and Sentence.CreateFromString(), as it was never used in those functions anyway --- Word.CreateFromString() retrieves the factor delimiter from StaticData directly.
Diffstat (limited to 'moses/Sentence.cpp')
-rw-r--r--moses/Sentence.cpp16
1 files changed, 10 insertions, 6 deletions
diff --git a/moses/Sentence.cpp b/moses/Sentence.cpp
index 7eebdb928..e61ce9ec9 100644
--- a/moses/Sentence.cpp
+++ b/moses/Sentence.cpp
@@ -53,7 +53,7 @@ Sentence::~Sentence()
int Sentence::Read(std::istream& in,const std::vector<FactorType>& factorOrder)
{
- const std::string& factorDelimiter = StaticData::Instance().GetFactorDelimiter();
+ // const std::string& factorDelimiter = StaticData::Instance().GetFactorDelimiter();
std::string line;
std::map<std::string, std::string> meta;
@@ -147,7 +147,8 @@ int Sentence::Read(std::istream& in,const std::vector<FactorType>& factorOrder)
}
}
- Phrase::CreateFromString(Input, factorOrder, line, factorDelimiter, NULL);
+ // Phrase::CreateFromString(Input, factorOrder, line, factorDelimiter, NULL);
+ Phrase::CreateFromString(Input, factorOrder, line, NULL);
// placeholders
ProcessPlaceholders(placeholders);
@@ -311,11 +312,14 @@ std::vector <ChartTranslationOptions*> Sentence::GetXmlChartTranslationOptions()
return ret;
}
-void Sentence::CreateFromString(const std::vector<FactorType> &factorOrder
- , const std::string &phraseString
- , const std::string &factorDelimiter)
+void
+Sentence::
+CreateFromString(const std::vector<FactorType> &factorOrder,
+ const std::string &phraseString)
+// , const std::string &factorDelimiter)
{
- Phrase::CreateFromString(Input, factorOrder, phraseString, factorDelimiter, NULL);
+ // Phrase::CreateFromString(Input, factorOrder, phraseString, factorDelimiter, NULL);
+ Phrase::CreateFromString(Input, factorOrder, phraseString, NULL);
}