diff --git a/Cargo.toml b/Cargo.toml index cabe4b7d4..61fbd43d9 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,7 +1,7 @@ [workspace.package] edition = "2021" license = "MIT" -rust-version = "1.83" +rust-version = "1.81" authors = ["clabby", "refcell"] homepage = "https://github.com/anton-rs/kona" repository = "https://github.com/anton-rs/kona" diff --git a/build/asterisc/asterisc-repro.dockerfile b/build/asterisc/asterisc-repro.dockerfile index 03b328562..a644df173 100644 --- a/build/asterisc/asterisc-repro.dockerfile +++ b/build/asterisc/asterisc-repro.dockerfile @@ -76,7 +76,7 @@ RUN apt-get update && apt-get install -y --no-install-recommends \ pkg-config # Install rust -ENV RUST_VERSION=1.83.0 +ENV RUST_VERSION=1.81.0 RUN curl https://sh.rustup.rs -sSf | bash -s -- -y --default-toolchain ${RUST_VERSION} --component rust-src ENV PATH="/root/.cargo/bin:${PATH}" diff --git a/crates/derive/src/attributes/stateful.rs b/crates/derive/src/attributes/stateful.rs index 3af01d213..c9390da66 100644 --- a/crates/derive/src/attributes/stateful.rs +++ b/crates/derive/src/attributes/stateful.rs @@ -1,3 +1,4 @@ +#![allow(clippy::unnecessary_map_or)] //! The [`AttributesBuilder`] and it's default implementation. use crate::{ @@ -214,7 +215,7 @@ async fn derive_deposits( for l in r.logs.iter() { let curr_index = global_index; global_index += 1; - if l.data.topics().first().is_none_or(|i| *i != DEPOSIT_EVENT_ABI_HASH) { + if l.data.topics().first().map_or(true, |i| *i != DEPOSIT_EVENT_ABI_HASH) { continue; } if l.address != deposit_contract { diff --git a/crates/derive/src/stages/batch/batch_validator.rs b/crates/derive/src/stages/batch/batch_validator.rs index ad65c0214..4a5dd6241 100644 --- a/crates/derive/src/stages/batch/batch_validator.rs +++ b/crates/derive/src/stages/batch/batch_validator.rs @@ -1,3 +1,4 @@ +#![allow(clippy::unnecessary_map_or)] //! Contains the [BatchValidator] stage. use super::NextBatchProvider; @@ -55,7 +56,7 @@ where /// ## Returns /// - `true` if the origin is behind the parent origin. fn origin_behind(&self, parent: &L2BlockInfo) -> bool { - self.prev.origin().is_none_or(|origin| origin.number < parent.l1_origin.number) + self.prev.origin().map_or(true, |origin| origin.number < parent.l1_origin.number) } /// Updates the [BatchValidator]'s view of the L1 origin blocks.