In https://github.com/google/benchmark/pull/1493, the T const & overload of DoNotOptimize was deprecated because the compiler is still able to make assumptions about the value of the variable. However, it is unclear whether this concern would apply to an rvalue reference overload.
Describe the bug
In https://github.com/google/benchmark/pull/1493, the
T const &
overload ofDoNotOptimize
was deprecated because the compiler is still able to make assumptions about the value of the variable. However, it is unclear whether this concern would apply to an rvalue reference overload.To reproduce
Expected behavior
No warning is emitted.