summaryrefslogtreecommitdiff
path: root/klm/lm/vocab.cc
diff options
context:
space:
mode:
authorKenneth Heafield <github@kheafield.com>2011-11-03 20:08:43 +0000
committerKenneth Heafield <github@kheafield.com>2011-11-03 20:08:43 +0000
commit9b9d565a9300b3a2b80bbb952bbf88dd36860ce2 (patch)
treed2680e52e219e3faabe4e70a1835bbecf12b787d /klm/lm/vocab.cc
parentee9cd01805cb7f297c42bf7a513dbe09b50264e5 (diff)
Mostly minor changes like a missing header guard and bad documentation
Diffstat (limited to 'klm/lm/vocab.cc')
-rw-r--r--klm/lm/vocab.cc1
1 files changed, 1 insertions, 0 deletions
diff --git a/klm/lm/vocab.cc b/klm/lm/vocab.cc
index 03b0767a..ffec41ca 100644
--- a/klm/lm/vocab.cc
+++ b/klm/lm/vocab.cc
@@ -135,6 +135,7 @@ void SortedVocabulary::LoadedBinary(int fd, EnumerateVocab *to) {
end_ = begin_ + *(reinterpret_cast<const uint64_t*>(begin_) - 1);
ReadWords(fd, to);
SetSpecial(Index("<s>"), Index("</s>"), 0);
+ bound_ = end_ - begin_ + 1;
}
namespace {