Skip to content

Commit 4d7d3ae

Browse files
authored
Merge pull request #1665 from ldrumm/ref-noref
Prefer value over reference for `isPowerOf2`
2 parents 5136177 + 33256f5 commit 4d7d3ae

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

source/ur/ur.hpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -337,7 +337,7 @@ roundToHighestFactorOfGlobalSize(size_t &ThreadsPerBlockInDim,
337337

338338
// Returns whether or not Value is a power of 2
339339
template <typename T, typename = std::enable_if_t<std::is_integral_v<T>>>
340-
bool isPowerOf2(const T &Value) {
340+
bool isPowerOf2(const T Value) {
341341
return Value && !(Value & (Value - 1));
342342
}
343343

0 commit comments

Comments
 (0)