mirror of
https://github.com/fmtlib/fmt.git
synced 2024-11-25 19:50:05 +00:00
Revert adding constexpr to rotr to satisfy C++11 compilers
This commit is contained in:
parent
c04af4bfc7
commit
dba99bc860
@ -818,11 +818,11 @@ struct uint128_wrapper {
|
||||
};
|
||||
|
||||
// Compilers should be able to optimize this into the ror instruction.
|
||||
inline constexpr uint32_t rotr(uint32_t n, uint32_t r) noexcept {
|
||||
inline uint32_t rotr(uint32_t n, uint32_t r) noexcept {
|
||||
r &= 31;
|
||||
return (n >> r) | (n << (32 - r));
|
||||
}
|
||||
inline constexpr uint64_t rotr(uint64_t n, uint32_t r) noexcept {
|
||||
inline uint64_t rotr(uint64_t n, uint32_t r) noexcept {
|
||||
r &= 63;
|
||||
return (n >> r) | (n << (64 - r));
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user