diff options
| author | Ralf Jung <post@ralfj.de> | 2024-10-14 17:09:44 +0200 |
|---|---|---|
| committer | Ralf Jung <post@ralfj.de> | 2024-10-14 17:09:44 +0200 |
| commit | 543d226589d152a27a5c150e415b451e50986c79 (patch) | |
| tree | 6eebb25d13a6ace45d712257d931527662949fdc | |
| parent | 9d579f5358d6722fa20cbf243e201defbd5d84b3 (diff) | |
| download | rust-543d226589d152a27a5c150e415b451e50986c79.tar.gz rust-543d226589d152a27a5c150e415b451e50986c79.zip | |
clippy
| -rw-r--r-- | src/tools/miri/src/intrinsics/mod.rs | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/tools/miri/src/intrinsics/mod.rs b/src/tools/miri/src/intrinsics/mod.rs index 9f772cfa982..13eac60f911 100644 --- a/src/tools/miri/src/intrinsics/mod.rs +++ b/src/tools/miri/src/intrinsics/mod.rs @@ -301,6 +301,7 @@ pub trait EvalContextExt<'tcx>: crate::MiriInterpCxExt<'tcx> { let b = this.read_scalar(b)?.to_f32()?; let c = this.read_scalar(c)?.to_f32()?; let fuse: bool = this.machine.rng.get_mut().gen(); + #[allow(clippy::arithmetic_side_effects)] // float ops don't overflow let res = if fuse { // FIXME: Using host floats, to work around https://github.com/rust-lang/rustc_apfloat/issues/11 a.to_host().mul_add(b.to_host(), c.to_host()).to_soft() @@ -316,6 +317,7 @@ pub trait EvalContextExt<'tcx>: crate::MiriInterpCxExt<'tcx> { let b = this.read_scalar(b)?.to_f64()?; let c = this.read_scalar(c)?.to_f64()?; let fuse: bool = this.machine.rng.get_mut().gen(); + #[allow(clippy::arithmetic_side_effects)] // float ops don't overflow let res = if fuse { // FIXME: Using host floats, to work around https://github.com/rust-lang/rustc_apfloat/issues/11 a.to_host().mul_add(b.to_host(), c.to_host()).to_soft() |
