Skip to content

Commit

Permalink
fix: clippy fixes for rust 1.80
Browse files Browse the repository at this point in the history
Signed-off-by: Dori Medini <dori@starkware.co>
  • Loading branch information
dorimedini-starkware committed Jul 25, 2024
1 parent 57a5f42 commit ee6aa89
Show file tree
Hide file tree
Showing 5 changed files with 11 additions and 15 deletions.
9 changes: 7 additions & 2 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -53,8 +53,8 @@ ark-ec = "0.4.2"
ark-ff = "0.4.0-alpha.7"
ark-secp256k1 = "0.4.0"
ark-secp256r1 = "0.4.0"
assert_matches = "1.5.0"
assert-json-diff = "2.0.2"
assert_matches = "1.5.0"
async-recursion = "1.1.0"
async-stream = "0.3.3"
async-trait = "0.1.79"
Expand Down Expand Up @@ -176,7 +176,12 @@ zstd = "0.13.1"
future-incompatible = "deny"
nonstandard-style = "deny"
rust-2018-idioms = "deny"
unused = "deny"
unexpected_cfgs = { level = "warn", check-cfg = ['cfg(coverage_nightly)'] }
# Need a priority of `-1` so it is before the `warnings` lint. See
# [here](https://github.com/rust-lang/cargo/issues/12918) for details on the issue, and
# [here](https://rust-lang.github.io/rust-clippy/master/index.html#/lint_groups_priority) for the
# clippy failure this solves.
unused = { level = "deny", priority = -1 }
warnings = "deny"

[workspace.lints.clippy]
Expand Down
7 changes: 1 addition & 6 deletions crates/blockifier/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,7 @@
// length to pointer type ([not necessarily true](https://github.com/rust-lang/rust/issues/65473),
// but it is a reasonable assumption for now), this attribute protects against potential overflow
// when converting usize to u128.
#![cfg(any(
target_pointer_width = "16",
target_pointer_width = "32",
target_pointer_width = "64",
target_pointer_width = "128"
))]
#![cfg(any(target_pointer_width = "16", target_pointer_width = "32", target_pointer_width = "64",))]

#[cfg(feature = "jemalloc")]
// Override default allocator.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@ impl TempSkeletonNode {
/// Assumes the nodes are:
/// * Descendants of the given index.
/// * A non-empty array.
///
/// Note that the if the LCA is the root, the path will be empty (0 length).
fn get_path_to_lca(
root_index: &NodeIndex,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ use crate::component_definitions::ComponentRequestAndResponseSender;
///
/// # Fields
/// - `tx`: An asynchronous sender channel for transmitting
/// `ComponentRequestAndResponseSender<Request, Response>` messages.
/// `ComponentRequestAndResponseSender<Request, Response>` messages.
///
/// # Example
/// ```rust
Expand Down
7 changes: 1 addition & 6 deletions crates/native_blockifier/src/lib.rs
Original file line number Diff line number Diff line change
@@ -1,10 +1,5 @@
// The blockifier crate supports only these specific architectures.
#![cfg(any(
target_pointer_width = "16",
target_pointer_width = "32",
target_pointer_width = "64",
target_pointer_width = "128"
))]
#![cfg(any(target_pointer_width = "16", target_pointer_width = "32", target_pointer_width = "64",))]

pub mod errors;
pub mod py_block_executor;
Expand Down

0 comments on commit ee6aa89

Please sign in to comment.