From 33da311ee9373f2463eb4397ae304c8733f6fce4 Mon Sep 17 00:00:00 2001 From: Tomas Janousek Date: Mon, 18 Apr 2022 19:18:02 +0200 Subject: [PATCH 1/3] fix build with stable rust negative_impls feature doesn't seem to be needed --- src/lib.rs | 1 - 1 file changed, 1 deletion(-) diff --git a/src/lib.rs b/src/lib.rs index 7aa06db..5b77ba4 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -1,5 +1,4 @@ #![warn(clippy::all)] -#![feature(negative_impls)] pub mod adapted_iter; pub mod adapters; From 6eb090b839c677b735fa10197e71d95fb7d4098b Mon Sep 17 00:00:00 2001 From: Tomas Janousek Date: Mon, 18 Apr 2022 19:20:35 +0200 Subject: [PATCH 2/3] CI: reenable stable rust in test matrix --- .github/workflows/ci.yml | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index b1b6f3f..71d4082 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -22,14 +22,15 @@ jobs: strategy: matrix: build: + - stable - nightly - nightly-musl - nightly-arm - macos include: - #- build: stable - # os: ubuntu-18.04 - # rust: stable + - build: stable + os: ubuntu-18.04 + rust: stable - build: nightly os: ubuntu-18.04 rust: nightly From 45b7b7ae6fa07636b1a6c0f3b5b096d332c165be Mon Sep 17 00:00:00 2001 From: Tomas Janousek Date: Mon, 18 Apr 2022 22:44:01 +0200 Subject: [PATCH 3/3] rustfmt --- src/adapters/postproc.rs | 16 +++++++++++----- src/preproc_cache.rs | 4 +++- 2 files changed, 14 insertions(+), 6 deletions(-) diff --git a/src/adapters/postproc.rs b/src/adapters/postproc.rs index 0048200..7164ee7 100644 --- a/src/adapters/postproc.rs +++ b/src/adapters/postproc.rs @@ -158,7 +158,10 @@ impl Read for ReadErr { } }*/ -pub fn postproc_encoding<'a, R: Read+'a>(line_prefix: &str, inp: R) -> Result> { +pub fn postproc_encoding<'a, R: Read + 'a>( + line_prefix: &str, + inp: R, +) -> Result> { // TODO: parse these options from ripgrep's configuration let encoding = None; // detect bom but usually assume utf8 let bom_sniffing = true; @@ -184,9 +187,7 @@ pub fn postproc_encoding<'a, R: Read+'a>(line_prefix: &str, inp: R) -> Result Result>>> { +fn open_cache_db( + path: &Path, +) -> Result>>> { std::fs::create_dir_all(path)?; use rkv::backend::LmdbEnvironmentFlags;