Skip to content

Commit ff7f074

Browse files
committed
chore: add more linting
1 parent 9c1cc35 commit ff7f074

File tree

2 files changed

+6
-1
lines changed

2 files changed

+6
-1
lines changed

Cargo.toml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,11 @@ unsafe_code = "forbid"
3434
unused_qualifications = "warn"
3535

3636
[workspace.lints.clippy]
37+
# Restrictions
38+
panic_in_result_fn = "warn"
39+
todo = "warn"
40+
unwrap_used = "warn"
41+
# Pedantics without being too noisy
3742
cargo = { level = "warn", priority = -1 }
3843
pedantic = { level = "warn", priority = -1 }
3944

src/renamer.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -253,7 +253,7 @@ impl ParseCallbacks for Renamer {
253253
.next()
254254
.or_else(|| {
255255
if self.debug {
256-
let name = enum_name.unwrap();
256+
let name = enum_name.unwrap_or_default();
257257
println!("cargo::warning=Unrecognized enum variant {name} :: {value}");
258258
}
259259
None

0 commit comments

Comments
 (0)