diff --git a/benches/bench_main.rs b/benches/bench_main.rs index 0c1a62c..b2fc5ba 100644 --- a/benches/bench_main.rs +++ b/benches/bench_main.rs @@ -1,3 +1,5 @@ +#![cfg_attr(feature = "fail-on-warnings", deny(warnings))] + use { criterion::{ black_box, criterion_group, criterion_main, Bencher, Benchmark, Criterion, Throughput, @@ -26,7 +28,7 @@ where { let value: T = rng.gen(); if value != T::zero() { - return value; + value } else { T::one() } diff --git a/build.rs b/build.rs index 0c34fa6..f54d0f9 100644 --- a/build.rs +++ b/build.rs @@ -7,6 +7,7 @@ #![allow(dead_code)] #![allow(unused_variables)] +#![cfg_attr(feature = "fail-on-warnings", deny(warnings))] use std::env; use std::ffi::OsString;