Skip to content

Commit

Permalink
Merge pull request #284 from stepchowfun/default-numeric-fallback
Browse files Browse the repository at this point in the history
Forbid the default numeric fallback
  • Loading branch information
stepchowfun authored Jan 9, 2024
2 parents af53bcd + 15df47a commit d8faa63
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
1 change: 1 addition & 0 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ readme = "README.md"

[lints]
clippy.all = "deny"
clippy.default_numeric_fallback = "deny"
clippy.pedantic = "deny"
rust.warnings = "deny"

Expand Down
2 changes: 1 addition & 1 deletion src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ impl Threshold {
)
})
.and_then(|f| {
if f.is_normal() && (0.0..=100.0).contains(&f) {
if f.is_normal() && (0.0_f64..=100.0_f64).contains(&f) {
Ok(f)
} else {
Err(io::Error::new(
Expand Down

0 comments on commit d8faa63

Please sign in to comment.