Skip to content

Commit f12a039

Browse files
committed
apply heavy clippy lints to remove all panics
1 parent 362e281 commit f12a039

File tree

8 files changed

+23
-2
lines changed

8 files changed

+23
-2
lines changed

Cargo.toml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -117,3 +117,8 @@ debug = true
117117
name = "game_of_life"
118118
path = "examples/game_of_life.rs"
119119
required-features = ["lua54", "bevy/file_watcher", "bevy/multi_threaded"]
120+
121+
[workspace.lints.clippy]
122+
panic = "deny"
123+
unwrap_used = "deny"
124+
expect_used = "deny"

clippy.toml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,5 @@
11
type-complexity-threshold = 1000
22
too-many-arguments-threshold = 999
3+
allow-panic-in-tests = true
4+
allow-unwrap-in-tests = true
5+
allow-expect-in-tests = true

crates/bevy_api_gen/Cargo.toml

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -58,5 +58,3 @@ chrono = "0.4"
5858

5959
[build-dependencies]
6060
toml = "0.8"
61-
62-
[workspace]

crates/bevy_mod_scripting_core/Cargo.toml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,3 +39,6 @@ itertools = "0.13"
3939

4040
[dev-dependencies]
4141
test_utils = { workspace = true }
42+
43+
[lints]
44+
workspace = true

crates/bevy_mod_scripting_functions/Cargo.toml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,3 +33,6 @@ bevy = { workspace = true, features = [
3333
uuid = "1.11"
3434
smol_str = "0.2.2"
3535
bevy_mod_scripting_core = { workspace = true }
36+
37+
[lints]
38+
workspace = true

crates/languages/bevy_mod_scripting_lua/Cargo.toml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -54,3 +54,6 @@ regex = "1.11"
5454
[[test]]
5555
name = "lua_tests"
5656
harness = false
57+
58+
[lints]
59+
workspace = true

crates/languages/bevy_mod_scripting_rhai/Cargo.toml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,3 +30,6 @@ regex = "1.11"
3030
[[test]]
3131
name = "rhai_tests"
3232
harness = false
33+
34+
[lints]
35+
workspace = true

crates/languages/bevy_mod_scripting_rune/Cargo.toml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,3 +20,6 @@ bevy = { workspace = true, default-features = false }
2020
rune = "0.13.1"
2121
rune-modules = "0.13.1"
2222
anyhow = "1.0.75"
23+
24+
[lints]
25+
workspace = true

0 commit comments

Comments
 (0)