mirror of
https://github.com/moses-smt/mosesdecoder.git
synced 2024-12-29 06:52:34 +03:00
Remove unnecessary const gimmicks
This commit is contained in:
parent
bb06091713
commit
74e90343d6
@ -18,14 +18,12 @@ int BilingualLMState::Compare(const FFState& other) const
|
||||
////////////////////////////////////////////////////////////////
|
||||
BilingualLM::BilingualLM(const std::string &line)
|
||||
: StatefulFeatureFunction(1, line),
|
||||
word_factortype(0),
|
||||
BOS_word(BOS_word_actual),
|
||||
EOS_word(EOS_word_actual) {
|
||||
word_factortype(0) {
|
||||
FactorCollection& factorFactory = FactorCollection::Instance(); //Factor Factory to use for BOS_ and EOS_
|
||||
BOS_factor = factorFactory.AddFactor(BOS_);
|
||||
BOS_word_actual.SetFactor(0, BOS_factor);
|
||||
BOS_word.SetFactor(0, BOS_factor);
|
||||
EOS_factor = factorFactory.AddFactor(EOS_);
|
||||
EOS_word_actual.SetFactor(0, EOS_factor);
|
||||
EOS_word.SetFactor(0, EOS_factor);
|
||||
|
||||
}
|
||||
|
||||
|
@ -96,10 +96,8 @@ protected:
|
||||
FactorType pos_factortype;
|
||||
const Factor* BOS_factor;
|
||||
const Factor* EOS_factor;
|
||||
mutable Word BOS_word_actual;
|
||||
mutable Word EOS_word_actual;
|
||||
const Word& BOS_word;
|
||||
const Word& EOS_word;
|
||||
mutable Word BOS_word;
|
||||
mutable Word EOS_word;
|
||||
|
||||
public:
|
||||
BilingualLM(const std::string &line);
|
||||
|
Loading…
Reference in New Issue
Block a user