diff --git a/Cargo.toml b/Cargo.toml index f4bfc2f..a6b129a 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "redisearch_api" -version = "0.4.1" +version = "0.4.2" authors = ["Gavrie Philipson ", "Guy Korland "] edition = "2018" description = "Rust RediSearch API binding" @@ -14,7 +14,7 @@ crate-type = ["cdylib"] [dependencies] -redis-module = { version="0.9.1", features = ["experimental-api"]} +redis-module = { version="0.9.2", features = ["experimental-api"]} bitflags = "1.1" libc = "0.2" time = "0.1" @@ -22,7 +22,7 @@ enum-primitive-derive = "0.1.2" num-traits = "0.2.8" [build-dependencies] -bindgen = "0.51" +bindgen = "0.54" cmake = "0.1" [features] diff --git a/build.rs b/build.rs index b194dca..f9bc442 100644 --- a/build.rs +++ b/build.rs @@ -13,6 +13,8 @@ fn main() { .whitelist_var("(RS|RediSearch|REDISEARCH_|GC_POLICY).*") .whitelist_function("RediSearch.*") .blacklist_item("RedisModule.*") + .blacklist_type("__darwin_.*") + .size_t_is_usize(true) .raw_line("use redis_module::raw::{RedisModuleCtx, RedisModuleString};") .generate() .expect("error generating RediSearch bindings"); diff --git a/src/index.rs b/src/index.rs index a9d46ea..0b56d84 100644 --- a/src/index.rs +++ b/src/index.rs @@ -172,7 +172,7 @@ impl Iterator for ResultsIterator<'_> { // A null pointer means we have no results. return None; } - let mut len = 0usize; + let mut len = 0; let key = unsafe { let raw_key = raw::RediSearch_ResultsIteratorNext(self.inner, self.index.inner, &mut len)