Skip to content

Commit

Permalink
Inherit lints from workspace for programs/sbf (#4463)
Browse files Browse the repository at this point in the history
  • Loading branch information
LucasSte authored Jan 14, 2025
1 parent a93f0fe commit 30111d0
Show file tree
Hide file tree
Showing 46 changed files with 139 additions and 1 deletion.
5 changes: 4 additions & 1 deletion programs/sbf/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,10 @@ edition = "2021"

[workspace.lints.rust.unexpected_cfgs]
level = "warn"
check-cfg = ['cfg(target_os, values("solana"))']
check-cfg = [
'cfg(target_os, values("solana"))',
'cfg(feature, values("custom-panic", "custom-heap"))'
]

[workspace.dependencies]
array-bytes = "=1.4.1"
Expand Down
3 changes: 3 additions & 0 deletions programs/sbf/rust/128bit/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -14,3 +14,6 @@ solana-sbf-rust-128bit-dep = { workspace = true }

[lib]
crate-type = ["cdylib"]

[lints]
workspace = true
3 changes: 3 additions & 0 deletions programs/sbf/rust/account_mem/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -13,3 +13,6 @@ solana-program = { workspace = true }

[lib]
crate-type = ["cdylib"]

[lints]
workspace = true
3 changes: 3 additions & 0 deletions programs/sbf/rust/alloc/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -13,3 +13,6 @@ solana-program = { workspace = true }

[lib]
crate-type = ["cdylib"]

[lints]
workspace = true
3 changes: 3 additions & 0 deletions programs/sbf/rust/alt_bn128/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -15,3 +15,6 @@ solana-program = { workspace = true }

[lib]
crate-type = ["cdylib"]

[lints]
workspace = true
3 changes: 3 additions & 0 deletions programs/sbf/rust/alt_bn128_compression/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -15,3 +15,6 @@ solana-program = { workspace = true }

[lib]
crate-type = ["cdylib"]

[lints]
workspace = true
3 changes: 3 additions & 0 deletions programs/sbf/rust/big_mod_exp/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -17,3 +17,6 @@ solana-program = { workspace = true }

[lib]
crate-type = ["cdylib"]

[lints]
workspace = true
3 changes: 3 additions & 0 deletions programs/sbf/rust/call_args/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -14,3 +14,6 @@ solana-program = { workspace = true }

[lib]
crate-type = ["cdylib"]

[lints]
workspace = true
3 changes: 3 additions & 0 deletions programs/sbf/rust/call_depth/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -13,3 +13,6 @@ solana-program = { workspace = true }

[lib]
crate-type = ["cdylib"]

[lints]
workspace = true
3 changes: 3 additions & 0 deletions programs/sbf/rust/caller_access/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -13,3 +13,6 @@ solana-program = { workspace = true }

[lib]
crate-type = ["cdylib"]

[lints]
workspace = true
3 changes: 3 additions & 0 deletions programs/sbf/rust/curve25519/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -14,3 +14,6 @@ solana-program = { workspace = true }

[lib]
crate-type = ["cdylib"]

[lints]
workspace = true
3 changes: 3 additions & 0 deletions programs/sbf/rust/divide_by_zero/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -13,3 +13,6 @@ solana-program = { workspace = true }

[lib]
crate-type = ["cdylib"]

[lints]
workspace = true
3 changes: 3 additions & 0 deletions programs/sbf/rust/dup_accounts/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -13,3 +13,6 @@ solana-program = { workspace = true }

[lib]
crate-type = ["cdylib"]

[lints]
workspace = true
3 changes: 3 additions & 0 deletions programs/sbf/rust/error_handling/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -17,3 +17,6 @@ thiserror = { workspace = true }

[lib]
crate-type = ["cdylib"]

[lints]
workspace = true
3 changes: 3 additions & 0 deletions programs/sbf/rust/external_spend/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -13,3 +13,6 @@ solana-program = { workspace = true }

[lib]
crate-type = ["cdylib"]

[lints]
workspace = true
3 changes: 3 additions & 0 deletions programs/sbf/rust/finalize/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -13,3 +13,6 @@ solana-program = { workspace = true }

[lib]
crate-type = ["cdylib"]

[lints]
workspace = true
3 changes: 3 additions & 0 deletions programs/sbf/rust/get_minimum_delegation/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -13,3 +13,6 @@ solana-program = { workspace = true }

[lib]
crate-type = ["cdylib"]

[lints]
workspace = true
Original file line number Diff line number Diff line change
Expand Up @@ -13,3 +13,6 @@ solana-program = { workspace = true }

[lib]
crate-type = ["cdylib"]

[lints]
workspace = true
3 changes: 3 additions & 0 deletions programs/sbf/rust/instruction_introspection/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -13,3 +13,6 @@ solana-program = { workspace = true }

[lib]
crate-type = ["cdylib"]

[lints]
workspace = true
3 changes: 3 additions & 0 deletions programs/sbf/rust/invoke/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -16,3 +16,6 @@ solana-sbf-rust-realloc-dep = { workspace = true }

[lib]
crate-type = ["cdylib"]

[lints]
workspace = true
3 changes: 3 additions & 0 deletions programs/sbf/rust/invoke_and_error/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -13,3 +13,6 @@ solana-program = { workspace = true }

[lib]
crate-type = ["cdylib"]

[lints]
workspace = true
3 changes: 3 additions & 0 deletions programs/sbf/rust/invoke_and_ok/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -13,3 +13,6 @@ solana-program = { workspace = true }

[lib]
crate-type = ["cdylib"]

[lints]
workspace = true
3 changes: 3 additions & 0 deletions programs/sbf/rust/invoke_and_return/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -13,3 +13,6 @@ solana-program = { workspace = true }

[lib]
crate-type = ["cdylib"]

[lints]
workspace = true
3 changes: 3 additions & 0 deletions programs/sbf/rust/invoked/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -14,3 +14,6 @@ solana-sbf-rust-invoked-dep = { workspace = true }

[lib]
crate-type = ["cdylib"]

[lints]
workspace = true
3 changes: 3 additions & 0 deletions programs/sbf/rust/iter/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -13,3 +13,6 @@ solana-program = { workspace = true }

[lib]
crate-type = ["cdylib"]

[lints]
workspace = true
3 changes: 3 additions & 0 deletions programs/sbf/rust/log_data/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -13,3 +13,6 @@ solana-program = { workspace = true }

[lib]
crate-type = ["cdylib"]

[lints]
workspace = true
3 changes: 3 additions & 0 deletions programs/sbf/rust/many_args/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -14,3 +14,6 @@ solana-sbf-rust-many-args-dep = { workspace = true }

[lib]
crate-type = ["cdylib"]

[lints]
workspace = true
3 changes: 3 additions & 0 deletions programs/sbf/rust/mem/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -14,3 +14,6 @@ solana-sbf-rust-mem-dep = { workspace = true }

[lib]
crate-type = ["cdylib"]

[lints]
workspace = true
3 changes: 3 additions & 0 deletions programs/sbf/rust/noop/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -13,3 +13,6 @@ solana-program = { workspace = true }

[lib]
crate-type = ["cdylib"]

[lints]
workspace = true
3 changes: 3 additions & 0 deletions programs/sbf/rust/param_passing/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -14,3 +14,6 @@ solana-sbf-rust-param-passing-dep = { workspace = true }

[lib]
crate-type = ["cdylib"]

[lints]
workspace = true
3 changes: 3 additions & 0 deletions programs/sbf/rust/poseidon/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -15,3 +15,6 @@ solana-program = { workspace = true }

[lib]
crate-type = ["cdylib"]

[lints]
workspace = true
3 changes: 3 additions & 0 deletions programs/sbf/rust/rand/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -15,3 +15,6 @@ solana-program = { workspace = true }

[lib]
crate-type = ["cdylib"]

[lints]
workspace = true
3 changes: 3 additions & 0 deletions programs/sbf/rust/realloc/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -14,3 +14,6 @@ solana-sbf-rust-realloc-dep = { workspace = true }

[lib]
crate-type = ["cdylib"]

[lints]
workspace = true
3 changes: 3 additions & 0 deletions programs/sbf/rust/realloc_invoke/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -15,3 +15,6 @@ solana-sbf-rust-realloc-invoke-dep = { workspace = true }

[lib]
crate-type = ["cdylib"]

[lints]
workspace = true
3 changes: 3 additions & 0 deletions programs/sbf/rust/remaining_compute_units/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -13,3 +13,6 @@ solana-program = { workspace = true }

[lib]
crate-type = ["cdylib"]

[lints]
workspace = true
3 changes: 3 additions & 0 deletions programs/sbf/rust/ro_account_modify/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -13,3 +13,6 @@ solana-program = { workspace = true }

[lib]
crate-type = ["cdylib"]

[lints]
workspace = true
3 changes: 3 additions & 0 deletions programs/sbf/rust/secp256k1_recover/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -15,3 +15,6 @@ solana-secp256k1-recover = { workspace = true }

[lib]
crate-type = ["cdylib"]

[lints]
workspace = true
3 changes: 3 additions & 0 deletions programs/sbf/rust/sha/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -14,3 +14,6 @@ solana-program = { workspace = true }

[lib]
crate-type = ["cdylib"]

[lints]
workspace = true
3 changes: 3 additions & 0 deletions programs/sbf/rust/sibling_inner_instructions/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -13,3 +13,6 @@ solana-program = { workspace = true }

[lib]
crate-type = ["cdylib"]

[lints]
workspace = true
3 changes: 3 additions & 0 deletions programs/sbf/rust/sibling_instructions/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -13,3 +13,6 @@ solana-program = { workspace = true }

[lib]
crate-type = ["cdylib"]

[lints]
workspace = true
3 changes: 3 additions & 0 deletions programs/sbf/rust/simulation/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -13,3 +13,6 @@ solana-program = { workspace = true }

[lib]
crate-type = ["cdylib"]

[lints]
workspace = true
3 changes: 3 additions & 0 deletions programs/sbf/rust/spoof1/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -13,3 +13,6 @@ solana-program = { workspace = true }

[lib]
crate-type = ["cdylib"]

[lints]
workspace = true
3 changes: 3 additions & 0 deletions programs/sbf/rust/spoof1_system/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -13,3 +13,6 @@ solana-program = { workspace = true }

[lib]
crate-type = ["cdylib"]

[lints]
workspace = true
3 changes: 3 additions & 0 deletions programs/sbf/rust/syscall-get-epoch-stake/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -13,3 +13,6 @@ solana-program = { workspace = true }

[lib]
crate-type = ["cdylib"]

[lints]
workspace = true
3 changes: 3 additions & 0 deletions programs/sbf/rust/upgradeable/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -14,3 +14,6 @@ solana-program = { workspace = true }
[lib]
name = "solana_sbf_rust_upgradeable"
crate-type = ["cdylib"]

[lints]
workspace = true
3 changes: 3 additions & 0 deletions programs/sbf/rust/upgraded/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -14,3 +14,6 @@ solana-program = { workspace = true }
[lib]
name = "solana_sbf_rust_upgraded"
crate-type = ["cdylib"]

[lints]
workspace = true

0 comments on commit 30111d0

Please sign in to comment.