* Fix vocab read/write

This commit is contained in:
Matthew Honnibal 2015-09-10 14:44:38 +02:00
parent 31ccf494e6
commit f634191e27
1 changed files with 2 additions and 1 deletions

View File

@ -199,8 +199,9 @@ cdef class Vocab:
cdef hash_t key cdef hash_t key
for key, addr in self._by_hash.items(): for key, addr in self._by_hash.items():
lexeme = <LexemeC*>addr lexeme = <LexemeC*>addr
fp.write_from(&lexeme.orth, sizeof(lexeme.orth), 1)
fp.write_from(&lexeme.flags, sizeof(lexeme.flags), 1) fp.write_from(&lexeme.flags, sizeof(lexeme.flags), 1)
fp.write_from(&lexeme.id, sizeof(lexeme.flags), 1) fp.write_from(&lexeme.id, sizeof(lexeme.id), 1)
fp.write_from(&lexeme.length, sizeof(lexeme.length), 1) fp.write_from(&lexeme.length, sizeof(lexeme.length), 1)
fp.write_from(&lexeme.orth, sizeof(lexeme.orth), 1) fp.write_from(&lexeme.orth, sizeof(lexeme.orth), 1)
fp.write_from(&lexeme.lower, sizeof(lexeme.lower), 1) fp.write_from(&lexeme.lower, sizeof(lexeme.lower), 1)