| OLD | NEW |
| 1 // Copyright 2008 Google Inc. All Rights Reserved. | 1 // Copyright 2008 Google Inc. All Rights Reserved. |
| 2 | 2 |
| 3 #include "chrome/third_party/hunspell/google/bdict_writer.h" | 3 #include "third_party/hunspell/google/bdict_writer.h" |
| 4 | 4 |
| 5 #include "base/logging.h" | 5 #include "base/logging.h" |
| 6 #include "base/string_util.h" | 6 #include "base/string_util.h" |
| 7 #include "chrome/third_party/hunspell/google/bdict.h" | 7 #include "third_party/hunspell/google/bdict.h" |
| 8 | 8 |
| 9 namespace hunspell { | 9 namespace hunspell { |
| 10 | 10 |
| 11 // Represents one node the word trie in memory. This does not have to be very | 11 // Represents one node the word trie in memory. This does not have to be very |
| 12 // efficient since it is only used when building. | 12 // efficient since it is only used when building. |
| 13 class DicNode { | 13 class DicNode { |
| 14 public: | 14 public: |
| 15 enum StorageType { | 15 enum StorageType { |
| 16 UNDEFINED, // Uninitialized storage type. | 16 UNDEFINED, // Uninitialized storage type. |
| 17 LEAF, // Word with no additional string data. | 17 LEAF, // Word with no additional string data. |
| (...skipping 477 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 495 // Add the header now that we know the offsets. | 495 // Add the header now that we know the offsets. |
| 496 hunspell::BDict::AffHeader* header = | 496 hunspell::BDict::AffHeader* header = |
| 497 reinterpret_cast<hunspell::BDict::AffHeader*>(&(*output)[header_offset]); | 497 reinterpret_cast<hunspell::BDict::AffHeader*>(&(*output)[header_offset]); |
| 498 header->affix_group_offset = static_cast<uint32>(affix_group_offset); | 498 header->affix_group_offset = static_cast<uint32>(affix_group_offset); |
| 499 header->affix_rule_offset = static_cast<uint32>(affix_rule_offset); | 499 header->affix_rule_offset = static_cast<uint32>(affix_rule_offset); |
| 500 header->rep_offset = static_cast<uint32>(rep_offset); | 500 header->rep_offset = static_cast<uint32>(rep_offset); |
| 501 header->other_offset = static_cast<uint32>(other_offset); | 501 header->other_offset = static_cast<uint32>(other_offset); |
| 502 } | 502 } |
| 503 | 503 |
| 504 } // namespace hunspell | 504 } // namespace hunspell |
| OLD | NEW |