Skip to content

Commit 270f6f8

Browse files
committed
wip
1 parent 1e83520 commit 270f6f8

File tree

14 files changed

+127
-5
lines changed

14 files changed

+127
-5
lines changed

Cargo.toml

+66
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,72 @@ repository = "https://github.com/Jon-Becker/heimdall-rs"
4040
keywords = ["ethereum", "web3", "decompiler", "evm", "crypto"]
4141
exclude = [".github/"]
4242

43+
[workspace.lints]
44+
rust.missing_debug_implementations = "warn"
45+
rust.missing_docs = "warn"
46+
rust.unreachable_pub = "warn"
47+
rust.unused_must_use = "deny"
48+
rust.rust_2018_idioms = "deny"
49+
rustdoc.all = "warn"
50+
51+
[workspace.lints.clippy]
52+
# These are some of clippy's nursery (i.e., experimental) lints that we like.
53+
# By default, nursery lints are allowed. Some of the lints below have made good
54+
# suggestions which we fixed. The others didn't have any findings, so we can
55+
# assume they don't have that many false positives. Let's enable them to
56+
# prevent future problems.
57+
branches_sharing_code = "warn"
58+
clear_with_drain = "warn"
59+
derive_partial_eq_without_eq = "warn"
60+
empty_line_after_outer_attr = "warn"
61+
equatable_if_let = "warn"
62+
imprecise_flops = "warn"
63+
iter_on_empty_collections = "warn"
64+
iter_with_drain = "warn"
65+
large_stack_frames = "warn"
66+
manual_clamp = "warn"
67+
mutex_integer = "warn"
68+
needless_pass_by_ref_mut = "warn"
69+
nonstandard_macro_braces = "warn"
70+
or_fun_call = "warn"
71+
path_buf_push_overwrite = "warn"
72+
read_zero_byte_vec = "warn"
73+
redundant_clone = "warn"
74+
suboptimal_flops = "warn"
75+
suspicious_operation_groupings = "warn"
76+
trailing_empty_array = "warn"
77+
trait_duplication_in_bounds = "warn"
78+
transmute_undefined_repr = "warn"
79+
trivial_regex = "warn"
80+
tuple_array_conversions = "warn"
81+
uninhabited_references = "warn"
82+
unused_peekable = "warn"
83+
unused_rounding = "warn"
84+
useless_let_if_seq = "warn"
85+
86+
# These are nursery lints which have findings. Allow them for now. Some are not
87+
# quite mature enough for use in our codebase and some we don't really want.
88+
# Explicitly listing should make it easier to fix in the future.
89+
as_ptr_cast_mut = "allow"
90+
cognitive_complexity = "allow"
91+
collection_is_never_read = "allow"
92+
debug_assert_with_mut_call = "allow"
93+
empty_line_after_doc_comments = "allow"
94+
fallible_impl_from = "allow"
95+
future_not_send = "allow"
96+
iter_on_single_items = "allow"
97+
missing_const_for_fn = "allow"
98+
needless_collect = "allow"
99+
non_send_fields_in_send_ty = "allow"
100+
option_if_let_else = "allow"
101+
redundant_pub_crate = "allow"
102+
significant_drop_in_scrutinee = "allow"
103+
significant_drop_tightening = "allow"
104+
string_lit_as_bytes = "allow"
105+
type_repetition_in_bounds = "allow"
106+
unnecessary_struct_initialization = "allow"
107+
use_self = "allow"
108+
43109
[workspace.dependencies]
44110
heimdall-core = { path = "crates/core" }
45111
heimdall-cache = { path = "crates/cache" }

crates/cache/Cargo.toml

+3
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,9 @@ repository.workspace = true
1010
keywords.workspace = true
1111
exclude.workspace = true
1212

13+
[lints]
14+
workspace = true
15+
1316
[lib]
1417
bench = false
1518

crates/cfg/Cargo.toml

+8-1
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,9 @@ repository.workspace = true
1010
keywords.workspace = true
1111
exclude.workspace = true
1212

13+
[lints]
14+
workspace = true
15+
1316
[lib]
1417
bench = false
1518

@@ -25,7 +28,11 @@ eyre = "0.6.12"
2528
futures = "0.3.30"
2629
lazy_static = "1.4.0"
2730
petgraph = "0.6.2"
28-
alloy = { version = "0.3.3", features = ["full", "rpc-types-debug", "rpc-types-trace"] }
31+
alloy = { version = "0.3.3", features = [
32+
"full",
33+
"rpc-types-debug",
34+
"rpc-types-trace",
35+
] }
2936

3037
heimdall-disassembler.workspace = true
3138
heimdall-vm.workspace = true

crates/cli/Cargo.toml

+9-1
Original file line numberDiff line numberDiff line change
@@ -26,9 +26,17 @@ tracing = "0.1.40"
2626
tracing-subscriber = "0.3.18"
2727
eyre = "0.6.12"
2828
alloy-json-abi = "0.8.3"
29-
alloy = { version = "0.3.3", features = ["full", "rpc-types-debug", "rpc-types-trace"] }
29+
alloy = { version = "0.3.3", features = [
30+
"full",
31+
"rpc-types-debug",
32+
"rpc-types-trace",
33+
] }
3034
async-trait = "0.1.51"
3135

36+
[lints]
37+
workspace = true
38+
39+
3240
[[bin]]
3341
name = "heimdall"
3442
path = "src/main.rs"

crates/common/Cargo.toml

+3
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,9 @@ exclude.workspace = true
1313
[lib]
1414
bench = false
1515

16+
[lints]
17+
workspace = true
18+
1619
[dependencies]
1720
async-openai = "0.26.0"
1821
clap = { workspace = true, features = ["derive"] }

crates/config/Cargo.toml

+3
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,9 @@ exclude.workspace = true
1313
[lib]
1414
bench = false
1515

16+
[lints]
17+
workspace = true
18+
1619
[dependencies]
1720
heimdall-common = { workspace = true }
1821
clap = { workspace = true, features = ["derive"] }

crates/core/Cargo.toml

+4-1
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,9 @@ exclude.workspace = true
1313
[lib]
1414
bench = false
1515

16+
[lints]
17+
workspace = true
18+
1619
[dependencies]
1720
async-recursion = "1.0.5"
1821
thiserror = "1.0.50"
@@ -33,7 +36,7 @@ derive_builder = "0.12.0"
3336
async-convert = "1.0.0"
3437
futures = "0.3.28"
3538
tracing = "0.1.40"
36-
alloy-json-abi = { version = "0.7.6", features = ["serde_json"]}
39+
alloy-json-abi = { version = "0.7.6", features = ["serde_json"] }
3740

3841
# modules
3942
heimdall-cfg = { workspace = true }

crates/decode/Cargo.toml

+3
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,9 @@ exclude.workspace = true
1313
[lib]
1414
bench = false
1515

16+
[lints]
17+
workspace = true
18+
1619
[dependencies]
1720
heimdall-config = { workspace = true }
1821
heimdall-common = { workspace = true }

crates/decompile/Cargo.toml

+3
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,9 @@ exclude.workspace = true
1313
[lib]
1414
bench = false
1515

16+
[lints]
17+
workspace = true
18+
1619
[dependencies]
1720
heimdall-config = { workspace = true }
1821
heimdall-common = { workspace = true }

crates/disassemble/Cargo.toml

+3
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,9 @@ exclude.workspace = true
1313
[lib]
1414
bench = false
1515

16+
[lints]
17+
workspace = true
18+
1619
[dependencies]
1720
heimdall-config = { workspace = true }
1821
heimdall-common = { workspace = true }

crates/dump/Cargo.toml

+8-1
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,9 @@ exclude.workspace = true
1313
[lib]
1414
bench = false
1515

16+
[lints]
17+
workspace = true
18+
1619
[dependencies]
1720
heimdall-config = { workspace = true }
1821
heimdall-common = { workspace = true }
@@ -24,5 +27,9 @@ tracing = "0.1.40"
2427
eyre = "0.6.12"
2528
tokio = { version = "1", features = ["full"] }
2629
futures = "0.3.30"
27-
alloy = { version = "0.3.3", features = ["full", "rpc-types-debug", "rpc-types-trace"] }
30+
alloy = { version = "0.3.3", features = [
31+
"full",
32+
"rpc-types-debug",
33+
"rpc-types-trace",
34+
] }
2835
hashbrown = "0.14.5"

crates/inspect/Cargo.toml

+8-1
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,9 @@ exclude.workspace = true
1313
[lib]
1414
bench = false
1515

16+
[lints]
17+
workspace = true
18+
1619
[dependencies]
1720
heimdall-config = { workspace = true }
1821
heimdall-common = { workspace = true }
@@ -28,6 +31,10 @@ async-convert = "1.0.0"
2831
futures = "0.3.28"
2932
async-recursion = "1.0.5"
3033
tokio = { version = "1", features = ["full"] }
31-
alloy = { version = "0.3.3", features = ["full", "rpc-types-debug", "rpc-types-trace"] }
34+
alloy = { version = "0.3.3", features = [
35+
"full",
36+
"rpc-types-debug",
37+
"rpc-types-trace",
38+
] }
3239
serde_json = "1.0"
3340
hashbrown = "0.14.5"

crates/tracing/Cargo.toml

+3
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,9 @@ exclude.workspace = true
1313
[lib]
1414
bench = false
1515

16+
[lints]
17+
workspace = true
18+
1619
[dependencies]
1720
clap = { workspace = true, features = ["derive"] }
1821
tracing = "0.1.40"

crates/vm/Cargo.toml

+3
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,9 @@ exclude.workspace = true
1313
[lib]
1414
bench = false
1515

16+
[lints]
17+
workspace = true
18+
1619
[dependencies]
1720
async-openai = "0.10.0"
1821
clap = { workspace = true, features = ["derive"] }

0 commit comments

Comments
 (0)