From 82e2f0e98b210d4840a6ca0890fd9cd42892a6cd Mon Sep 17 00:00:00 2001 From: Yosh Date: Thu, 22 Feb 2024 14:02:43 +0100 Subject: [PATCH 1/7] apply automated cargo clippy --fix --- src/native/delay.rs | 2 +- src/native/heap.rs | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/native/delay.rs b/src/native/delay.rs index 69e8fcd..22b7084 100644 --- a/src/native/delay.rs +++ b/src/native/delay.rs @@ -116,7 +116,7 @@ impl Future for Delay { return Poll::Ready(()); } - state.waker.register(&cx.waker()); + state.waker.register(cx.waker()); // Now that we've registered, do the full check of our own internal // state. If we've fired the first bit is set, and if we've been diff --git a/src/native/heap.rs b/src/native/heap.rs index dca0b19..4c31482 100644 --- a/src/native/heap.rs +++ b/src/native/heap.rs @@ -66,7 +66,7 @@ impl Heap { pub fn peek(&self) -> Option<&T> { self.assert_consistent(); - self.items.get(0).map(|i| &i.0) + self.items.first().map(|i| &i.0) } pub fn pop(&mut self) -> Option { @@ -191,7 +191,7 @@ impl Heap { } } - for (i, &(ref item, _)) in self.items.iter().enumerate() { + for (i, (item, _)) in self.items.iter().enumerate() { if i > 0 { assert!(*item >= self.items[(i - 1) / 2].0, "bad at index: {}", i); } @@ -272,7 +272,7 @@ mod tests { for t in v { h.push(t); } - return h; + h } #[test] From af1eb7b128a95e5d31a17113c05d311f70c1e726 Mon Sep 17 00:00:00 2001 From: Yosh Date: Thu, 22 Feb 2024 14:09:20 +0100 Subject: [PATCH 2/7] Update ci.yml --- .github/workflows/ci.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 22cf059..e42317e 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -1,8 +1,8 @@ name: CI on: [push, pull_request] -env: - RUSTFLAGS: -Dwarnings +# env: +# RUSTFLAGS: -Dwarnings jobs: test: From a8a05484d3fd6e5d207b26bf3c0339985e3055cb Mon Sep 17 00:00:00 2001 From: Yosh Date: Thu, 22 Feb 2024 14:43:56 +0100 Subject: [PATCH 3/7] bump minimum CI version to 1.56 otherwise CI doesn't build --- .github/workflows/ci.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index e42317e..100fc57 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -2,7 +2,7 @@ name: CI on: [push, pull_request] # env: -# RUSTFLAGS: -Dwarnings +# RUSTFLAGS: -Dwarnings jobs: test: @@ -11,7 +11,7 @@ jobs: strategy: matrix: rust: - - 1.39.0 + - 1.56.0 - stable - beta - nightly From a87fcce47c15fd4bb26a1ff8a611c7d775d45c65 Mon Sep 17 00:00:00 2001 From: Yosh Date: Thu, 22 Feb 2024 14:48:08 +0100 Subject: [PATCH 4/7] bump CI to 1.60 as a minimum --- .github/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 100fc57..b04fdb7 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -11,7 +11,7 @@ jobs: strategy: matrix: rust: - - 1.56.0 + - 1.60.0 - stable - beta - nightly From 2e39432d861a941b34cd854cbf5d781eb5a41f11 Mon Sep 17 00:00:00 2001 From: Yosh Date: Thu, 22 Feb 2024 14:52:01 +0100 Subject: [PATCH 5/7] memchr requires 1.61 or higher --- .github/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index b04fdb7..8ba6652 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -11,7 +11,7 @@ jobs: strategy: matrix: rust: - - 1.60.0 + - 1.61.0 - stable - beta - nightly From fbda7a46f5a6f442b1d6ca0c9c23cda8576e2b46 Mon Sep 17 00:00:00 2001 From: Yosh Date: Thu, 22 Feb 2024 15:05:42 +0100 Subject: [PATCH 6/7] async-io requires 1.63 or higher --- .github/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 8ba6652..cf29e99 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -11,7 +11,7 @@ jobs: strategy: matrix: rust: - - 1.61.0 + - 1.63.0 - stable - beta - nightly From 19b18b4e3687a5619ecd84dd01161b0e15db27a6 Mon Sep 17 00:00:00 2001 From: Yosh Date: Thu, 22 Feb 2024 15:06:56 +0100 Subject: [PATCH 7/7] drop old rust tests --- .github/workflows/ci.yml | 3 --- 1 file changed, 3 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index cf29e99..c2d642a 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -11,10 +11,7 @@ jobs: strategy: matrix: rust: - - 1.63.0 - stable - - beta - - nightly steps: - uses: actions/checkout@master - name: Install Rust