Change the way we filter the documents

This commit is contained in:
Clément Renault 2020-01-14 13:30:12 +01:00
parent 681711fced
commit 40dab80dfa
No known key found for this signature in database
GPG key ID: 92ADA4E935E71FA4
3 changed files with 19 additions and 12 deletions

View file

@ -8,7 +8,7 @@ use serde::{Deserialize, Serialize};
///
/// It is used to inform the database the document you want to deserialize.
/// Helpful for custom ranking.
#[derive(Debug, Copy, Clone, Eq, PartialEq, PartialOrd, Ord, Hash)]
#[derive(Debug, Default, Copy, Clone, Eq, PartialEq, PartialOrd, Ord, Hash)]
#[cfg_attr(feature = "zerocopy", derive(AsBytes, FromBytes))]
#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
#[repr(C)]
@ -19,7 +19,7 @@ pub struct DocumentId(pub u64);
///
/// This is stored in the map, generated at index time,
/// extracted and interpreted at search time.
#[derive(Debug, Copy, Clone, PartialEq, Eq, PartialOrd, Ord, Hash)]
#[derive(Debug, Default, Copy, Clone, PartialEq, Eq, PartialOrd, Ord, Hash)]
#[cfg_attr(feature = "zerocopy", derive(AsBytes, FromBytes))]
#[repr(C)]
pub struct DocIndex {