add static lifetime to constexpr values to force compile time evaluation where possible

Signed-off-by: arades79 <scravers@protonmail.com>
This commit is contained in:
arades79
2023-02-14 12:33:11 -05:00
parent 5f5a6e4b2e
commit 45e13b03f3
101 changed files with 309 additions and 303 deletions
+1 -1
View File
@@ -209,7 +209,7 @@ private:
std::size_t WorkerBufferSize(u32 channel_count) {
ASSERT_MSG(channel_count == 1 || channel_count == 2, "Invalid channel count");
constexpr int num_streams = 1;
constexpr static int num_streams = 1;
const int num_stereo_streams = channel_count == 2 ? 1 : 0;
return opus_multistream_decoder_get_size(num_streams, num_stereo_streams);
}