Skip to content

Commit

Permalink
Mark some conditionally-used parameters as maybe_unused
Browse files Browse the repository at this point in the history
  • Loading branch information
kcat committed Mar 16, 2024
1 parent c118daf commit 44f691e
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions al/buffer.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -285,7 +285,7 @@ constexpr auto SanitizeAlignment(FmtType type, ALuint align) noexcept -> ALuint


/** Loads the specified data into the buffer, using the specified format. */
void LoadData(ALCcontext *context, ALbuffer *ALBuf, ALsizei freq, ALuint size,
void LoadData(ALCcontext *context [[maybe_unused]], ALbuffer *ALBuf, ALsizei freq, ALuint size,
const FmtChannels DstChannels, const FmtType DstType, const std::byte *SrcData,
ALbitfieldSOFT access)
{
Expand Down Expand Up @@ -392,7 +392,7 @@ void LoadData(ALCcontext *context, ALbuffer *ALBuf, ALsizei freq, ALuint size,
}

/** Prepares the buffer to use the specified callback, using the specified format. */
void PrepareCallback(ALCcontext *context, ALbuffer *ALBuf, ALsizei freq,
void PrepareCallback(ALCcontext *context [[maybe_unused]], ALbuffer *ALBuf, ALsizei freq,
const FmtChannels DstChannels, const FmtType DstType, ALBUFFERCALLBACKTYPESOFT callback,
void *userptr)
{
Expand Down Expand Up @@ -449,7 +449,7 @@ void PrepareCallback(ALCcontext *context, ALbuffer *ALBuf, ALsizei freq,
}

/** Prepares the buffer to use caller-specified storage. */
void PrepareUserPtr(ALCcontext *context, ALbuffer *ALBuf, ALsizei freq,
void PrepareUserPtr(ALCcontext *context [[maybe_unused]], ALbuffer *ALBuf, ALsizei freq,
const FmtChannels DstChannels, const FmtType DstType, std::byte *sdata, const ALuint sdatalen)
{
if(ALBuf->ref.load(std::memory_order_relaxed) != 0 || ALBuf->MappedAccess != 0)
Expand Down

0 comments on commit 44f691e

Please sign in to comment.