diff --git a/src/structs/spec/vec.rs b/src/structs/spec/vec.rs index f0a9cbdf..9352365a 100644 --- a/src/structs/spec/vec.rs +++ b/src/structs/spec/vec.rs @@ -234,7 +234,7 @@ impl + Clone> UniformSphereSample for Vec2 { #[inline(always)] fn sample(f: |Vec2| -> ()) { for sample in SAMPLES_2_F64.iter() { - f(Cast::from(*sample)) + f(Cast::from(sample.clone())) } } } @@ -243,7 +243,7 @@ impl + Clone> UniformSphereSample for Vec3 { #[inline(always)] fn sample(f: |Vec3| -> ()) { for sample in SAMPLES_3_F64.iter() { - f(Cast::from(*sample)) + f(Cast::from(sample.clone())) } } }