aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorChris Robinson <[email protected]>2021-01-17 23:39:33 -0800
committerChris Robinson <[email protected]>2021-01-17 23:39:33 -0800
commitc3380d42011738ed91e356206532908403f337e4 (patch)
tree4b2c4e26ab541655900aa9bec365a5186d3cf81b
parent8ebf146c72f2695869912f9bdd91ce4062ca94b8 (diff)
Remove constexpr from a function
Various versions of GCC have a problem with it, and it doesn't really add much benefit anyway.
-rw-r--r--al/auxeffectslot.cpp7
1 files changed, 1 insertions, 6 deletions
diff --git a/al/auxeffectslot.cpp b/al/auxeffectslot.cpp
index 9a319126..4af2acf2 100644
--- a/al/auxeffectslot.cpp
+++ b/al/auxeffectslot.cpp
@@ -209,7 +209,7 @@ void RemoveActiveEffectSlots(const al::span<ALeffectslot*> auxslots, ALCcontext
}
-constexpr EffectSlotType EffectSlotTypeFromEnum(ALenum type)
+EffectSlotType EffectSlotTypeFromEnum(ALenum type)
{
switch(type)
{
@@ -231,12 +231,7 @@ constexpr EffectSlotType EffectSlotTypeFromEnum(ALenum type)
case AL_EFFECT_DEDICATED_DIALOGUE: return EffectSlotType::DedicatedDialog;
case AL_EFFECT_CONVOLUTION_REVERB_SOFT: return EffectSlotType::Convolution;
}
- /* GCC 5 doesn't like this in a constexpr function. Clang reports itself as
- * GCC 4 or 5, so explicitly allow that.
- */
-#if !defined(__GNUC__) || (__GNUC__ > 5) || defined(__clang__)
ERR("Unhandled effect enum: 0x%04x\n", type);
-#endif
return EffectSlotType::None;
}