You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
/__w/Q2RTX/Q2RTX/extern/openal-soft/alc/backends/alsa.cpp:396:11: warning: enumeration value 'SND_PCM_STATE_PRIVATE1' not handled in switch [-Wswitch]
396 | switch(state)
| ^
The compiler gives me that warning and so it's seems to me SND_PCM_STATE_PRIVATE1 is not handled. Is it by intention?
The text was updated successfully, but these errors were encountered:
As it's name suggests, it's a private state enumeration, that shouldn't be used by callers.
/** Private - used internally in the library - do not use*/SND_PCM_STATE_PRIVATE1=1024
Unfortunately it being placed in the public headers means the compiler can see it as a potential enumeration for snd_pcm_state_t variables, which the compiler expectedly warns about not being handled as a potential value. I'd really consider this a bug in ALSA's headers, making a private thing public that causes errant warnings in valid properly written code. The only ways to avoid it are either to use it, in opposition to the comment, or disable -Wswitch warnings (or add a default case for the same effect), which can hide bugs from unhandled public enum states that may be added in the future (or other changes that could cause an existing state to not be handled as it should be).
The compiler gives me that warning and so it's seems to me
SND_PCM_STATE_PRIVATE1
is not handled. Is it by intention?The text was updated successfully, but these errors were encountered: