This is two years old. Due to its age it’s most definitely not as efficient as it could be. This has no advantage over using if/elseif minus sugar.
If anything this is disadvantageous as it uses metatables very consistently and OOP is generally just slower than straight on code as Lua isn’t built with OOP in mind.
It’s also slower because if/elseif are built in to Lua which gives them great engine optimizations.
I have made a switch case module before but after the time since I’ve made it I’ve realized why Roblox doesn’t need it. It’s generally more clunky looking than if/elseif due to constant importation and how foreign it would look to other developers.
This just seemingly makes programming more bloated than using what the engine provides you for “better syntax” which is arguably deniable as it looks more like a Promise than a switch because of its reliance on OOP.