Skip to content
This repository was archived by the owner on Feb 1, 2024. It is now read-only.

Commit a30c69f

Browse files
committed
Fix manual_range_contains warnings
Signed-off-by: Joseph Livesey <joseph.livesey@btp.works>
1 parent c3c17bc commit a30c69f

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

perf/intkey_workload/src/main.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -182,7 +182,7 @@ fn get_arg_matches<'a>() -> ArgMatches<'a> {
182182
}
183183

184184
fn err_if_out_of_range(val: f32) -> Result<f32, IntKeyCliError> {
185-
if val < 0.0 || val > 1.0 {
185+
if !(0.0..=1.0).contains(&val) {
186186
return Err(IntKeyCliError {
187187
msg: "Value must be between 0.0 and 1.0, inclusively".to_string(),
188188
});

0 commit comments

Comments
 (0)