Fix linkage error on debug build with clang-13
Debug build with clang-13 fails with "undefined references" to the static const members in spu_channel class. This patch replaces the const definitions with constexpr constants.
This commit is contained in:
@@ -172,10 +172,10 @@ struct spu_channel
|
|||||||
atomic_t<u64> data;
|
atomic_t<u64> data;
|
||||||
|
|
||||||
public:
|
public:
|
||||||
static const u32 off_wait = 32;
|
static constexpr u32 off_wait = 32;
|
||||||
static const u32 off_count = 63;
|
static constexpr u32 off_count = 63;
|
||||||
static const u64 bit_wait = 1ull << off_wait;
|
static constexpr u64 bit_wait = 1ull << off_wait;
|
||||||
static const u64 bit_count = 1ull << off_count;
|
static constexpr u64 bit_count = 1ull << off_count;
|
||||||
|
|
||||||
// Returns true on success
|
// Returns true on success
|
||||||
bool try_push(u32 value)
|
bool try_push(u32 value)
|
||||||
|
|||||||
Reference in New Issue
Block a user