diff --git a/include/oneapi/math/rng/device/detail/geometric_impl.hpp b/include/oneapi/math/rng/device/detail/geometric_impl.hpp index 99749c65a..3466db8b7 100644 --- a/include/oneapi/math/rng/device/detail/geometric_impl.hpp +++ b/include/oneapi/math/rng/device/detail/geometric_impl.hpp @@ -64,7 +64,7 @@ class distribution_base> { std::is_same_v, double, float>::type; - FpType uni_res = engine.generate(FpType(0.0), FpType(1.0)); + auto uni_res = engine.generate(FpType(0.0), FpType(1.0)); FpType inv_ln = ln_wrapper(FpType(1.0) - p_); inv_ln = FpType(1.0) / inv_ln; if constexpr (EngineType::vec_size == 1) {