Reduce the DocumentId size from 64 to 32bits

This commit is contained in:
Kerollmops
2020-05-19 13:53:31 +02:00
parent 3bca31856d
commit 788e2202c9
12 changed files with 33 additions and 32 deletions

View File

@ -228,7 +228,7 @@ mod tests {
builder.into_inner().and_then(Set::from_bytes).unwrap()
}
const fn doc_index(document_id: u64, word_index: u16) -> DocIndex {
const fn doc_index(document_id: u32, word_index: u16) -> DocIndex {
DocIndex {
document_id: DocumentId(document_id),
attribute: 0,
@ -238,7 +238,7 @@ mod tests {
}
}
const fn doc_char_index(document_id: u64, word_index: u16, char_index: u16) -> DocIndex {
const fn doc_char_index(document_id: u32, word_index: u16, char_index: u16) -> DocIndex {
DocIndex {
document_id: DocumentId(document_id),
attribute: 0,